Force LD=ld.bfd for ghc compilation
This commit is contained in:
parent
c7a831a280
commit
e58e1c1954
20
lib/GHCup.hs
20
lib/GHCup.hs
@ -503,17 +503,21 @@ GhcWithLlvmCodeGen = YES|]
|
|||||||
()
|
()
|
||||||
compile bghc ghcdir workdir = do
|
compile bghc ghcdir workdir = do
|
||||||
lift $ $(logInfo) [i|configuring build|]
|
lift $ $(logInfo) [i|configuring build|]
|
||||||
|
|
||||||
|
-- force ld.bfd for build (others seem to misbehave, like lld from FreeBSD)
|
||||||
|
newEnv <- addToCurrentEnv [([s|LD|], [s|ld.bfd|])]
|
||||||
|
|
||||||
if
|
if
|
||||||
| tver >= [vver|8.8.0|] -> do
|
| tver >= [vver|8.8.0|] -> do
|
||||||
spaths <- catMaybes . fmap parseAbs <$> liftIO getSearchPath
|
spaths <- catMaybes . fmap parseAbs <$> liftIO getSearchPath
|
||||||
bghcPath <- (liftIO $ searchPath spaths bghc) !? NoDownload
|
bghcPath <- (liftIO $ searchPath spaths bghc) !? NoDownload
|
||||||
newEnv <- addToCurrentEnv [([s|GHC|], toFilePath bghcPath)]
|
lEM $ liftIO $ execLogged
|
||||||
lEM $ liftIO $ execLogged [s|./configure|]
|
[s|./configure|]
|
||||||
False
|
False
|
||||||
[[s|--prefix=|] <> toFilePath ghcdir]
|
[[s|--prefix=|] <> toFilePath ghcdir]
|
||||||
[rel|ghc-configure.log|]
|
[rel|ghc-configure.log|]
|
||||||
(Just workdir)
|
(Just workdir)
|
||||||
(Just newEnv)
|
(Just (([s|GHC|], toFilePath bghcPath) : newEnv))
|
||||||
| otherwise -> do
|
| otherwise -> do
|
||||||
lEM $ liftIO $ execLogged
|
lEM $ liftIO $ execLogged
|
||||||
[s|./configure|]
|
[s|./configure|]
|
||||||
@ -523,7 +527,7 @@ GhcWithLlvmCodeGen = YES|]
|
|||||||
]
|
]
|
||||||
[rel|ghc-configure.log|]
|
[rel|ghc-configure.log|]
|
||||||
(Just workdir)
|
(Just workdir)
|
||||||
Nothing
|
(Just newEnv)
|
||||||
|
|
||||||
case mbuildConfig of
|
case mbuildConfig of
|
||||||
Just bc -> liftIOException
|
Just bc -> liftIOException
|
||||||
|
Loading…
Reference in New Issue
Block a user