File tree Expand file tree Collapse file tree 4 files changed +6
-13
lines changed
cabal-testsuite/PackageTests/CCompilerOverride Expand file tree Collapse file tree 4 files changed +6
-13
lines changed Original file line number Diff line number Diff line change 11
2- #ifndef NOERROR1
3- #error "NOERROR1 was not passed"
4- #endif
5-
62#ifndef NOERROR2
73#error "NOERROR2 was not passed"
84#endif
95
10- #ifndef NOERROR3
11- #error "NOERROR3 was not passed"
12- #endif
13-
146#ifndef NOERROR4
157#error "NOERROR4 was not passed"
168#endif
Original file line number Diff line number Diff line change @@ -9,5 +9,5 @@ executable foo
99 main-is : Main.hs
1010 c-sources : foo.c
1111 build-depends : base
12- ghc-options : -DNOERROR4
12+ ghc-options : -optc=- DNOERROR4
1313 cc-options : -DNOERROR5 -march=native
Original file line number Diff line number Diff line change 11# Setup configure
22Configuring my-0.1...
3- Warning: [misplaced-c-opt] Instead of 'ghc-options: -DNOERROR4' use 'cpp-options: -DNOERROR4'
43# Setup build
Original file line number Diff line number Diff line change @@ -3,6 +3,10 @@ import Test.Cabal.Prelude
33-- Test that all the respective defines -DNOERROR... specified in various ways
44-- all end up routed to the C compiler. Otherwise the C file we depend on will
55-- not compile.
6+ --
7+ -- This has been largely gutted, as ghc 9.10 no longer passes through most
8+ -- of the defines we were testing; see
9+ -- https://gitlab.haskell.org/ghc/ghc/-/commit/8ff3134ed4aa323b0199ad683f72165e51a59ab6
610main = setupAndCabalTest $ do
711 skipUnlessGhcVersion " >= 8.8"
812 isWin <- isWindows
@@ -14,9 +18,7 @@ main = setupAndCabalTest $ do
1418 pwd ++ " /custom-cc" ++ if isWin then win_suffix else " "
1519
1620 setup " configure"
17- [ " --ghc-option=-DNOERROR1"
18- , " --ghc-option=-optc=-DNOERROR2"
19- , " --ghc-option=-optP=-DNOERROR3"
21+ [ " --ghc-option=-optc=-DNOERROR2"
2022 , " --with-gcc=" ++ customCC
2123 ]
2224 setup " build" [" -v2" ]
You can’t perform that action at this time.
0 commit comments