[Git][ghc/ghc][wip/hc2-test] Fixes to generating settings file
Matthew Pickering (@mpickering)
gitlab at gitlab.haskell.org
Wed Jan 17 16:16:14 UTC 2024
Matthew Pickering pushed to branch wip/hc2-test at Glasgow Haskell Compiler / GHC
Commits:
a5c773cc by GHC GitLab CI at 2024-01-17T16:15:59+00:00
Fixes to generating settings file
- - - - -
2 changed files:
- hadrian/src/Rules/Generate.hs
- hadrian/src/Settings/Builders/RunTest.hs
Changes:
=====================================
hadrian/src/Rules/Generate.hs
=====================================
@@ -229,7 +229,7 @@ generateRules = do
forM_ allStages $ \stage -> do
let prefix = root -/- stageString stage -/- "lib"
- go gen file = generate file (semiEmptyTarget stage) gen
+ go gen file = generate file (semiEmptyTarget (succStage stage)) gen
(prefix -/- "settings") %> go generateSettings
where
@@ -369,7 +369,7 @@ ghcWrapper stage = do
generateSettings :: Expr String
generateSettings = do
ctx <- getContext
- stage <- succStage <$> getStage
+ stage <- getStage
settings <- traverse sequence $
[ ("C compiler command", queryTarget stage ccPath)
, ("C compiler flags", queryTarget stage ccFlags)
=====================================
hadrian/src/Settings/Builders/RunTest.hs
=====================================
@@ -91,7 +91,7 @@ inTreeCompilerArgs stg = do
let ghcStage = succStage stg
(hasDynamicRts, hasThreadedRts) <- do
- ways <- interpretInContext (vanillaContext stg rts) getRtsWays
+ ways <- interpretInContext (vanillaContext ghcStage rts) getRtsWays
return (dynamic `elem` ways, threaded `elem` ways)
hasDynamic <- (dynamic ==) . Context.Type.way <$> (programContext stg ghc)
leadingUnderscore <- queryTargetTarget ghcStage tgtSymbolsHaveLeadingUnderscore
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/a5c773cca11cfb627fe57277bda16c45f398a213
--
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/a5c773cca11cfb627fe57277bda16c45f398a213
You're receiving this email because of your account on gitlab.haskell.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/ghc-commits/attachments/20240117/a32e8f52/attachment-0001.html>
More information about the ghc-commits
mailing list