[Git][ghc/ghc][wip/hadrian-windows-bindist-cross] 2 commits: hadrian: Don't pass `--gcc-options` as a --configure-arg to cabal configure
Ben Gamari (@bgamari)
gitlab at gitlab.haskell.org
Tue Oct 3 21:32:09 UTC 2023
Ben Gamari pushed to branch wip/hadrian-windows-bindist-cross at Glasgow Haskell Compiler / GHC
Commits:
47d9a787 by Matthew Pickering at 2023-10-03T17:32:00-04:00
hadrian: Don't pass `--gcc-options` as a --configure-arg to cabal configure
Stop passing -gcc-options which mixed together linker flags and
non-linker flags. There's no guarantee the C compiler will accept both
of these in each mode.
- - - - -
c7ff4b64 by Ben Gamari at 2023-10-03T17:32:00-04:00
configure: Probe stage0 link flags
- - - - -
2 changed files:
- configure.ac
- hadrian/src/Settings/Builders/Cabal.hs
Changes:
=====================================
configure.ac
=====================================
@@ -661,6 +661,7 @@ FP_CC_SUPPORTS_TARGET([$CC_STAGE0], [CONF_CC_OPTS_STAGE0], [CONF_CXX_OPTS_STAGE0
FP_CC_SUPPORTS_TARGET([$CC], [CONF_CC_OPTS_STAGE1], [CONF_CXX_OPTS_STAGE1])
FP_CC_SUPPORTS_TARGET([$CC], [CONF_CC_OPTS_STAGE2], [CONF_CXX_OPTS_STAGE2])
+FP_PROG_CC_LINKER_TARGET([CONF_CC_OPTS_STAGE0], [CONF_GCC_LINKER_OPTS_STAGE0])
FP_PROG_CC_LINKER_TARGET([CONF_CC_OPTS_STAGE1], [CONF_GCC_LINKER_OPTS_STAGE1])
FP_PROG_CC_LINKER_TARGET([CONF_CC_OPTS_STAGE2], [CONF_GCC_LINKER_OPTS_STAGE2])
=====================================
hadrian/src/Settings/Builders/Cabal.hs
=====================================
@@ -188,11 +188,9 @@ configureArgs cFlags' ldFlags' = do
, cFlags'
]
ldFlags = ldArgs <> ldFlags'
- cldFlags <- unwords <$> (cFlags <> ldFlags)
mconcat
[ conf "CFLAGS" cFlags
, conf "LDFLAGS" ldFlags
- , not (null cldFlags) ? arg ("--gcc-options=" ++ cldFlags)
, conf "--with-iconv-includes" $ arg =<< getSetting IconvIncludeDir
, conf "--with-iconv-libraries" $ arg =<< getSetting IconvLibDir
, conf "--with-gmp-includes" $ arg =<< getSetting GmpIncludeDir
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/a7779a9563cfd3593ef713cc8f5a7e0162bf4ed2...c7ff4b64bdd20d6628e0b6aee168d3bac23b04c3
--
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/a7779a9563cfd3593ef713cc8f5a7e0162bf4ed2...c7ff4b64bdd20d6628e0b6aee168d3bac23b04c3
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/20231003/d585d3ab/attachment-0001.html>
More information about the ghc-commits
mailing list