[commit: ghc] wip/nfs-locking: Add "--template" and "-I" arguments to hsc2HsArgs (efbe44f)
git at git.haskell.org
git at git.haskell.org
Thu Oct 26 23:46:55 UTC 2017
Repository : ssh://git@git.haskell.org/ghc
On branch : wip/nfs-locking
Link : http://ghc.haskell.org/trac/ghc/changeset/efbe44f845b88e3885e1c63adcf66c57c5af1f77/ghc
>---------------------------------------------------------------
commit efbe44f845b88e3885e1c63adcf66c57c5af1f77
Author: Moritz Angermann <moritz.angermann at gmail.com>
Date: Sat Dec 26 17:38:05 2015 +0800
Add "--template" and "-I" arguments to hsc2HsArgs
This should fix #35.
To have this fully working, #44 needs to be solved as well.
>---------------------------------------------------------------
efbe44f845b88e3885e1c63adcf66c57c5af1f77
src/Settings/Builders/Hsc2Hs.hs | 3 +++
1 file changed, 3 insertions(+)
diff --git a/src/Settings/Builders/Hsc2Hs.hs b/src/Settings/Builders/Hsc2Hs.hs
index 0e31b4f..0c6172d 100644
--- a/src/Settings/Builders/Hsc2Hs.hs
+++ b/src/Settings/Builders/Hsc2Hs.hs
@@ -13,6 +13,7 @@ hsc2HsArgs = builder Hsc2Hs ? do
gmpDirs <- getSettingList GmpIncludeDirs
cFlags <- getCFlags
lFlags <- getLFlags
+ top <- getSetting GhcSourcePath
hArch <- getSetting HostArch
hOs <- getSetting HostOs
tArch <- getSetting TargetArch
@@ -32,6 +33,8 @@ hsc2HsArgs = builder Hsc2Hs ? do
, notStage0 ? arg ("--cflag=-D" ++ tArch ++ "_HOST_ARCH=1")
, notStage0 ? arg ("--cflag=-D" ++ tOs ++ "_HOST_OS=1" )
, arg ("--cflag=-D__GLASGOW_HASKELL__=" ++ version)
+ , arg $ "--template=" ++ top -/- "inplace/lib/template-hsc.h"
+ , arg $ "-I" ++ top -/- "inplace/lib/include/"
, arg =<< getInput
, arg "-o", arg =<< getOutput ]
More information about the ghc-commits
mailing list