Skip to content

Commit

Permalink
*.project.* files use program-options to specify -fno-ignore-asserts
Browse files Browse the repository at this point in the history
Simplifies *.project.* files a bit. It wasn't feasible before #7973,
as program-options were applied to dependencies as well, which is undesirable.
  • Loading branch information
ulysses4ever authored and mergify[bot] committed Aug 11, 2022
1 parent f4270fc commit e443774
Show file tree
Hide file tree
Showing 5 changed files with 17 additions and 56 deletions.
29 changes: 1 addition & 28 deletions cabal.project
Original file line number Diff line number Diff line change
Expand Up @@ -20,32 +20,5 @@ allow-newer:
constraints: rere -rere-cfg
constraints: these -assoc

-- So us hackers get all the assertion failures early:
--
-- NOTE: currently commented out, see
-- https://github.com/haskell/cabal/issues/3911
-- as a workaround we specify it for each package individually:
--
-- program-options
-- ghc-options: -fno-ignore-asserts
--
package Cabal
ghc-options: -fno-ignore-asserts

package cabal-testsuite
ghc-options: -fno-ignore-asserts

package Cabal-QuickCheck
ghc-options: -fno-ignore-asserts

package Cabal-tree-diff
ghc-options: -fno-ignore-asserts

package Cabal-described
ghc-options: -fno-ignore-asserts

package cabal-install-solver
ghc-options: -fno-ignore-asserts

package cabal-install
program-options
ghc-options: -fno-ignore-asserts
11 changes: 3 additions & 8 deletions cabal.project.coverage
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,9 @@ allow-newer: windns-0.1.0.1:base
constraints: rere -rere-cfg
constraints: these

program-options
ghc-options: -fno-ignore-asserts

-- NOTE: for library coverage in multi-project builds,
-- see:
--
Expand All @@ -39,41 +42,33 @@ constraints: these
-- the `cabal-install` library
--
package Cabal-syntax
ghc-options: -fno-ignore-asserts
coverage: False
library-coverage: False

package Cabal
ghc-options: -fno-ignore-asserts
coverage: False
library-coverage: False

package cabal-testsuite
ghc-options: -fno-ignore-asserts
coverage: False
library-coverage: False

package Cabal-QuickCheck
ghc-options: -fno-ignore-asserts
coverage: False
library-coverage: False

package Cabal-tree-diff
ghc-options: -fno-ignore-asserts
coverage: False
library-coverage: False

package Cabal-described
ghc-options: -fno-ignore-asserts
coverage: False
library-coverage: False

package cabal-install-solver
ghc-options: -fno-ignore-asserts
coverage: False
library-coverage: False

package cabal-install
ghc-options: -fno-ignore-asserts
coverage: True
library-coverage: True
13 changes: 0 additions & 13 deletions cabal.project.libonly
Original file line number Diff line number Diff line change
Expand Up @@ -11,17 +11,4 @@ tests: True
--optional-packages: */

program-options
-- So us hackers get all the assertion failures early:
--
-- NOTE: currently commented out, see
-- https://github.com/haskell/cabal/issues/3911
--
-- ghc-options: -fno-ignore-asserts
--
-- as a workaround we specify it for each package individually:
package Cabal-syntax
ghc-options: -fno-ignore-asserts
package Cabal
ghc-options: -fno-ignore-asserts
package cabal-testsuite
ghc-options: -fno-ignore-asserts
11 changes: 7 additions & 4 deletions cabal.project.validate
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,14 @@ constraints: these -assoc

write-ghc-environment-files: never

program-options
ghc-options: -fno-ignore-asserts

package Cabal-syntax
ghc-options: -Werror -fno-ignore-asserts
ghc-options: -Werror
package Cabal
ghc-options: -Werror -fno-ignore-asserts
ghc-options: -Werror
package cabal-testsuite
ghc-options: -Werror -fno-ignore-asserts
ghc-options: -Werror
package cabal-install
ghc-options: -Werror -fno-ignore-asserts
ghc-options: -Werror
9 changes: 6 additions & 3 deletions cabal.project.validate.libonly
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,15 @@ write-ghc-environment-files: never
constraints: rere -rere-cfg
constraints: these -assoc

program-options
ghc-options: -fno-ignore-asserts

package Cabal-syntax
ghc-options: -Werror -fno-ignore-asserts
ghc-options: -Werror
package Cabal
ghc-options: -Werror -fno-ignore-asserts
ghc-options: -Werror
package cabal-testsuite
ghc-options: -Werror -fno-ignore-asserts
ghc-options: -Werror

-- https://github.com/haskell-hvr/cryptohash-sha256/issues/12
allow-newer: cryptohash-sha256:base

0 comments on commit e443774

Please sign in to comment.