c95a5da43d333f51449a126f713d62c63a76f3e7
[ghc.git] / src / Settings / Builders / Configure.hs
1 module Settings.Builders.Configure (configureBuilderArgs) where
2
3 import Base
4 import Oracles.Config.Setting
5 import Oracles.WindowsPath
6 import Predicate
7 import Settings.Paths
8
9 configureBuilderArgs :: Args
10 configureBuilderArgs = mconcat
11 [ builder (Configure gmpBuildPath) ? do
12 hostPlatform <- getSetting HostPlatform
13 buildPlatform <- getSetting BuildPlatform
14 append [ "--enable-shared=no"
15 , "--host=" ++ hostPlatform
16 , "--build=" ++ buildPlatform ]
17
18 , builder (Configure libffiBuildPath) ? do
19 top <- getTopDirectory
20 targetPlatform <- getSetting TargetPlatform
21 append [ "--prefix=" ++ top -/- libffiBuildPath -/- "inst"
22 , "--libdir=" ++ top -/- libffiBuildPath -/- "inst/lib"
23 , "--enable-static=yes"
24 , "--enable-shared=no" -- TODO: add support for yes
25 , "--host=" ++ targetPlatform ]
26 ]