[commit: ghc] wip/nfs-locking: Add support for building ghc-pkg. (bbc6e4a)
git at git.haskell.org
git at git.haskell.org
Fri Oct 27 00:10:38 UTC 2017
Repository : ssh://git@git.haskell.org/ghc
On branch : wip/nfs-locking
Link : http://ghc.haskell.org/trac/ghc/changeset/bbc6e4a216c7853c6275757fe1a84bf0e5721281/ghc
>---------------------------------------------------------------
commit bbc6e4a216c7853c6275757fe1a84bf0e5721281
Author: Andrey Mokhov <andrey.mokhov at gmail.com>
Date: Sat Dec 12 00:41:49 2015 +0000
Add support for building ghc-pkg.
>---------------------------------------------------------------
bbc6e4a216c7853c6275757fe1a84bf0e5721281
src/GHC.hs | 16 +++++++++-------
src/Settings/Packages.hs | 4 ++--
2 files changed, 11 insertions(+), 9 deletions(-)
diff --git a/src/GHC.hs b/src/GHC.hs
index de482f4..eff2334 100644
--- a/src/GHC.hs
+++ b/src/GHC.hs
@@ -1,8 +1,8 @@
module GHC (
array, base, binPackageDb, binary, bytestring, cabal, compiler, containers,
- deepseq, directory, filepath, ghc, ghcCabal, ghcPrim, haskeline, hoopl, hpc,
- integerGmp, integerSimple, parallel, pretty, primitive, process, stm,
- templateHaskell, terminfo, time, transformers, unix, win32, xhtml,
+ deepseq, directory, filepath, ghc, ghcCabal, ghcPkg, ghcPrim, haskeline,
+ hoopl, hpc, integerGmp, integerSimple, parallel, pretty, primitive, process,
+ stm, templateHaskell, terminfo, time, transformers, unix, win32, xhtml,
defaultKnownPackages, defaultTargetDirectory, defaultProgramPath
) where
@@ -19,16 +19,16 @@ import Stage
defaultKnownPackages :: [Package]
defaultKnownPackages =
[ array, base, binPackageDb, binary, bytestring, cabal, compiler
- , containers, deepseq, directory, filepath, ghc, ghcCabal, ghcPrim
+ , containers, deepseq, directory, filepath, ghc, ghcCabal, ghcPkg, ghcPrim
, haskeline, hoopl, hpc, integerGmp, integerSimple, parallel, pretty
, primitive, process, stm, templateHaskell, terminfo, time, transformers
, unix, win32, xhtml ]
-- Package definitions
array, base, binPackageDb, binary, bytestring, cabal, compiler, containers,
- deepseq, directory, filepath, ghc, ghcCabal, ghcPrim, haskeline, hoopl, hpc,
- integerGmp, integerSimple, parallel, pretty, primitive, process, stm,
- templateHaskell, terminfo, time, transformers, unix, win32, xhtml :: Package
+ deepseq, directory, filepath, ghc, ghcCabal, ghcPkg, ghcPrim, haskeline,
+ hoopl, hpc, integerGmp, integerSimple, parallel, pretty, primitive, process,
+ stm, templateHaskell, terminfo, time, transformers, unix, win32, xhtml :: Package
array = library "array"
base = library "base"
@@ -43,6 +43,7 @@ directory = library "directory"
filepath = library "filepath"
ghc = topLevel "ghc-bin" `setPath` "ghc"
ghcCabal = utility "ghc-cabal"
+ghcPkg = utility "ghc-pkg"
ghcPrim = library "ghc-prim"
haskeline = library "haskeline"
hoopl = library "hoopl"
@@ -80,6 +81,7 @@ defaultProgramPath :: Stage -> Package -> Maybe FilePath
defaultProgramPath stage pkg
| pkg == ghc = program $ "ghc-stage" ++ show (fromEnum stage + 1)
| pkg == ghcCabal = program $ pkgName pkg
+ | pkg == ghcPkg = program $ pkgName pkg
| otherwise = Nothing
where
program name = Just $ pkgPath pkg -/- defaultTargetDirectory stage pkg
diff --git a/src/Settings/Packages.hs b/src/Settings/Packages.hs
index 5ac9c6e..9fbe936 100644
--- a/src/Settings/Packages.hs
+++ b/src/Settings/Packages.hs
@@ -25,8 +25,8 @@ packagesStage1 :: Packages
packagesStage1 = mconcat
[ packagesStage0
, append [ array, base, bytestring, containers, deepseq, directory, filepath
- , ghcCabal, ghcPrim, haskeline, integerLibrary, pretty, process
- , time ]
+ , ghcCabal, ghcPkg, ghcPrim, haskeline, integerLibrary, pretty
+ , process, time ]
, windowsHost ? append [win32]
, notM windowsHost ? append [unix]
, buildHaddock ? append [xhtml] ]
More information about the ghc-commits
mailing list