diff options
author | Andrey Mokhov <andrey.mokhov@gmail.com> | 2019-06-23 00:50:43 +0100 |
---|---|---|
committer | Marge Bot <ben+marge-bot@smart-cactus.org> | 2019-06-25 01:36:10 -0400 |
commit | 15b262237ab055f4afbf79588f76631a194a332f (patch) | |
tree | bb04ea8eb6e5a4fffdecc2010d7b4782589cfb7b /hadrian/src/Rules/Gmp.hs | |
parent | 581cbc28e143a4ed8e7f794ed1618161222a5646 (diff) | |
download | haskell-15b262237ab055f4afbf79588f76631a194a332f.tar.gz |
Fix cyclic dependencies when using --configure
This resolves #16809 (https://gitlab.haskell.org/ghc/ghc/issues/16809).
This patch removes the unnecessary dependency on configure-generated
flags `windowsHost`, `osxHost` and `iosHost`, using the information
provided by the module `System.Info` instead.
We also take care to use the `CrossCompiling` flag generated by the
configure script only after the latter had a chance to run.
Diffstat (limited to 'hadrian/src/Rules/Gmp.hs')
-rw-r--r-- | hadrian/src/Rules/Gmp.hs | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/hadrian/src/Rules/Gmp.hs b/hadrian/src/Rules/Gmp.hs index 5666ab3905..61fb4125d3 100644 --- a/hadrian/src/Rules/Gmp.hs +++ b/hadrian/src/Rules/Gmp.hs @@ -61,9 +61,8 @@ gmpRules = do -- Copy appropriate GMP header and object files gmpPath <- gmpBuildPathRules gmpPath -/- gmpLibraryH %> \header -> do - windows <- windowsHost configMk <- readFile' =<< (buildPath gmpContext <&> (-/- "config.mk")) - if not windows && -- TODO: We don't use system GMP on Windows. Fix? + if not windowsHost && -- TODO: We don't use system GMP on Windows. Fix? any (`isInfixOf` configMk) [ "HaveFrameworkGMP = YES", "HaveLibGmp = YES" ] then do putBuild "| GMP library/framework detected and will be used" |