Skip to content
This repository has been archived by the owner on Aug 2, 2020. It is now read-only.

Commit

Permalink
Add -Wno-sync-nand to ghcPrim's cbits/atomic.c
Browse files Browse the repository at this point in the history
See GHC ticket #9678
  • Loading branch information
snowleopard committed Feb 6, 2017
1 parent e908a4a commit 6e73b4d
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 2 deletions.
1 change: 1 addition & 0 deletions cfg/system.config.in
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ ar-supports-at-file = @ArSupportsAtFile@
cc-clang-backend = @CC_CLANG_BACKEND@
cc-llvm-backend = @CC_LLVM_BACKEND@
gcc-is-clang = @GccIsClang@
gcc-lt-44 = @GccLT44@
gcc-lt-46 = @GccLT46@
hs-cpp-args = @HaskellCPPArgs@

Expand Down
2 changes: 2 additions & 0 deletions src/Oracles/Config/Flag.hs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ import Oracles.Config.Setting
data Flag = ArSupportsAtFile
| CrossCompiling
| GccIsClang
| GccLt44
| GccLt46
| GhcUnregisterised
| LeadingUnderscore
Expand All @@ -29,6 +30,7 @@ flag f = do
ArSupportsAtFile -> "ar-supports-at-file"
CrossCompiling -> "cross-compiling"
GccIsClang -> "gcc-is-clang"
GccLt44 -> "gcc-lt-44"
GccLt46 -> "gcc-lt-46"
GhcUnregisterised -> "ghc-unregisterised"
LeadingUnderscore -> "leading-underscore"
Expand Down
9 changes: 7 additions & 2 deletions src/Settings/Packages/GhcPrim.hs
Original file line number Diff line number Diff line change
@@ -1,8 +1,13 @@
module Settings.Packages.GhcPrim (ghcPrimPackageArgs) where

import GHC
import Oracles.Config.Flag
import Predicate

ghcPrimPackageArgs :: Args
ghcPrimPackageArgs = package ghcPrim ?
builder GhcCabal ? arg "--flag=include-ghc-prim"
ghcPrimPackageArgs = package ghcPrim ? mconcat
[ builder GhcCabal ? arg "--flag=include-ghc-prim"

, builder (Cc CompileC) ?
(not <$> flag GccLt44) ?
input "//cbits/atomic.c" ? arg "-Wno-sync-nand" ]

0 comments on commit 6e73b4d

Please sign in to comment.