patch applied (cabal): Add a unuque identifier for installed packages (part 2 of 9)

Duncan Coutts duncan.coutts at worc.ox.ac.uk
Sat Aug 22 11:36:08 EDT 2009


Thu Aug  6 06:19:06 PDT 2009  Simon Marlow <marlowsd at gmail.com>
  * Add a unuque identifier for installed packages (part 2 of 9)
  Ignore-this: f3fba4465373bd4b7397384f08ca189e
  
  Note: this patch doesn't build on its own, you also need the rest of
  the patch series.
  
  Compatibility with older GHCs.  When reading a package database
  created by an older version of GHC without installedPackageIds, we
  have to fake an InstalledPackageId for the internal
  InstalledPackageInfo.
  
  So, when reading in an InstalledPackageInfo from an older GHC, we set
  the installedPackageId to be the textual representation of the
  PackageIdentifier: i.e. <package>-<version>.  Now, previously the
  depends field of InstalledPackageInfo was [PackageIdentifier], and is
  now [InstalledPackageId], so we will read each PackageIdentifier as an
  InstalledPackageId (a String).  The dependencies will still point to
  the correct package, however, because we have chosen the
  installedPackageId to be the textual representation of the
  PackageIdentifier.

    M ./Distribution/Simple/GHC/IPI641.hs -1 +7
    M ./Distribution/Simple/GHC/IPI642.hs -2 +6
    M ./Distribution/Simple/Program/HcPkg.hs -3 +20

View patch online:
http://darcs.haskell.org/cabal/_darcs/patches/20090806131906-12142-e3ff1a46d8be6752f0a8fb488cece5a74807f2f9.gz



More information about the cabal-devel mailing list