Minor revision
[hadrian.git] / src / Settings / Packages / IntegerGmp.hs
index 9ad160f..72a70ce 100644 (file)
@@ -1,11 +1,10 @@
 module Settings.Packages.IntegerGmp (integerGmpPackageArgs, gmpBuildPath) where
 
 import Base
-import Expression
-import GHC (integerGmp)
-import Predicates (builder, builderGcc, package)
-import Settings.Paths
+import GHC
 import Oracles.Config.Setting
+import Predicate
+import Settings.Paths
 
 -- TODO: move build artefacts to buildRootPath, see #113
 -- TODO: Is this needed?
@@ -16,12 +15,14 @@ integerGmpPackageArgs :: Args
 integerGmpPackageArgs = package integerGmp ? do
     let includeGmp = "-I" ++ gmpBuildPath -/- "include"
     gmpIncludeDir <- getSetting GmpIncludeDir
-    gmpLibDir <- getSetting GmpLibDir
+    gmpLibDir     <- getSetting GmpLibDir
 
-    mconcat [ builder GhcCabal ? mconcat
+    mconcat [ builder Cc ? arg includeGmp
+
+            , builder GhcCabal ? mconcat
               [ (null gmpIncludeDir && null gmpLibDir) ?
                 arg "--configure-option=--with-intree-gmp"
               , appendSub "--configure-option=CFLAGS" [includeGmp]
-              , appendSub "--gcc-options"             [includeGmp] ]
-
-            , builderGcc ? arg includeGmp ]
+              , appendSub "--gcc-options"             [includeGmp]
+              ]
+            ]