[commit: ghc] master: Cause "make install" to install dynamic libraries (#8194) (865956a)
git at git.haskell.org
git at git.haskell.org
Sun Sep 15 19:48:58 CEST 2013
Repository : ssh://git@git.haskell.org/ghc
On branch : master
Link : http://ghc.haskell.org/trac/ghc/changeset/865956a6ccd88e71aa07a33667242b95ecf98793/ghc
>---------------------------------------------------------------
commit 865956a6ccd88e71aa07a33667242b95ecf98793
Author: Bryan O'Sullivan <bos at serpentine.com>
Date: Fri Sep 13 13:13:04 2013 -0700
Cause "make install" to install dynamic libraries (#8194)
Our special ghc-cabal command needs to be told that we are building with
dynamic library support when it does its copying. We do so by passing an
extra parameter from ghc.mk.
>---------------------------------------------------------------
865956a6ccd88e71aa07a33667242b95ecf98793
ghc.mk | 3 ++-
utils/ghc-cabal/Main.hs | 10 ++++++----
2 files changed, 8 insertions(+), 5 deletions(-)
diff --git a/ghc.mk b/ghc.mk
index 82e9e5c..2597ee9 100644
--- a/ghc.mk
+++ b/ghc.mk
@@ -918,7 +918,8 @@ install_packages: rts/dist/package.conf.install
'$(DESTDIR)' \
'$(prefix)' \
'$(ghclibdir)' \
- '$(docdir)/html/libraries'))
+ '$(docdir)/html/libraries' \
+ '$(GhcLibWays)'))
"$(INSTALLED_GHC_PKG_REAL)" --force --global-package-db "$(INSTALLED_PACKAGE_CONF)" update rts/dist/package.conf.install
$(foreach p, $(INSTALL_PACKAGES), \
$(call make-command, \
diff --git a/utils/ghc-cabal/Main.hs b/utils/ghc-cabal/Main.hs
index 7d1d9bc..8fa2c29 100644
--- a/utils/ghc-cabal/Main.hs
+++ b/utils/ghc-cabal/Main.hs
@@ -40,9 +40,10 @@ main = do hSetBuffering stdout LineBuffering
doCheck dir
"copy" : dir : distDir
: strip : myDestDir : myPrefix : myLibdir : myDocdir
- : args' ->
+ : ghcLibWays : args' ->
doCopy dir distDir
strip myDestDir myPrefix myLibdir myDocdir
+ ("dyn" `elem` words ghcLibWays)
args'
"register" : dir : distDir : ghc : ghcpkg : topdir
: myDestDir : myPrefix : myLibdir : myDocdir
@@ -127,11 +128,11 @@ runHsColour directory distdir args
$ defaultMainArgs ("hscolour" : "--builddir" : distdir : args)
doCopy :: FilePath -> FilePath
- -> FilePath -> FilePath -> FilePath -> FilePath -> FilePath
+ -> FilePath -> FilePath -> FilePath -> FilePath -> FilePath -> Bool
-> [String]
-> IO ()
doCopy directory distDir
- strip myDestDir myPrefix myLibdir myDocdir
+ strip myDestDir myPrefix myLibdir myDocdir withSharedLibs
args
= withCurrentDirectory directory $ do
let copyArgs = ["copy", "--builddir", distDir]
@@ -172,7 +173,8 @@ doCopy directory distDir
progs' <- configureProgram verbosity stripProgram' progs
let lbi' = lbi {
withPrograms = progs',
- installDirTemplates = idts
+ installDirTemplates = idts,
+ withSharedLib = withSharedLibs
}
f pd lbi' us flags
More information about the ghc-commits
mailing list