[Git][ghc/ghc][master] hadrian: Properly partition options in sourceArgs

Marge Bot gitlab at gitlab.haskell.org
Sun Jun 9 15:49:13 UTC 2019



 Marge Bot pushed to branch master at Glasgow Haskell Compiler / GHC


Commits:
970e4802 by Matthew Pickering at 2019-06-09T15:49:09Z
hadrian: Properly partition options in sourceArgs

Previously if you build the `ghc` package then it would has the default
opts and the library opts. This is different behaviour to make where the
library opts are only reserved for things in the `libraries`
subdirectory (I believe)

Fixes #16716

- - - - -


1 changed file:

- hadrian/src/Settings/Default.hs


Changes:

=====================================
hadrian/src/Settings/Default.hs
=====================================
@@ -179,7 +179,10 @@ sourceArgs :: SourceArgs -> Args
 sourceArgs SourceArgs {..} = builder Ghc ? mconcat
     [ hsDefault
     , getContextData hcOpts
-    , libraryPackage   ? hsLibrary
+    -- `compiler` is also a library but the specific arguments that we want
+    -- to apply to that are given by the hsCompiler option. `ghc` is an
+    -- executable so we don't have to exclude that.
+    , libraryPackage   ? notM (packageOneOf [compiler]) ? hsLibrary
     , package compiler ? hsCompiler
     , package ghc      ? hsGhc ]
 



View it on GitLab: https://gitlab.haskell.org/ghc/ghc/commit/970e480230bc8422d9bd9a6f1011def86befc34a

-- 
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/commit/970e480230bc8422d9bd9a6f1011def86befc34a
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/20190609/58819f20/attachment-0001.html>


More information about the ghc-commits mailing list