Skip to content

Commit

Permalink
Drop '>=' in suggestions for cabal-version (fix haskell#7088)
Browse files Browse the repository at this point in the history
Co-authored-by:    Jeremy Scott <[email protected]>
Co-authored-by:    Artem Pelenitsyn <[email protected]>
  • Loading branch information
ulysses4ever and Jeremy Scott committed Jun 10, 2022
1 parent 87bfc00 commit 2116671
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions Cabal/src/Distribution/PackageDescription/Check.hs
Original file line number Diff line number Diff line change
Expand Up @@ -299,7 +299,7 @@ checkExecutable pkg exe =
&& takeExtension (modulePath exe) `notElem` [".hs", ".lhs"]) $
PackageDistInexcusable $
"The package uses a C/C++/obj-C source file for the 'main-is' field. "
++ "To use this feature you must specify 'cabal-version: >= 1.18'."
++ "To use this feature you must specify 'cabal-version: 1.18'."

-- check that all autogen-modules appear on other-modules
, check
Expand Down Expand Up @@ -343,7 +343,7 @@ checkTestSuite pkg test =
, checkSpecVersion pkg CabalSpecV1_18 (mainIsNotHsExt && not mainIsWrongExt) $
PackageDistInexcusable $
"The package uses a C/C++/obj-C source file for the 'main-is' field. "
++ "To use this feature you must specify 'cabal-version: >= 1.18'."
++ "To use this feature you must specify 'cabal-version: 1.18'."

-- check that all autogen-modules appear on other-modules
, check
Expand Down Expand Up @@ -1192,7 +1192,7 @@ checkCabalVersion pkg =
(not . null $ extraDocFiles pkg) $
PackageDistInexcusable $
"To use the 'extra-doc-files' field the package needs to specify "
++ "at least 'cabal-version: >= 1.18'."
++ "at least 'cabal-version: 1.18'."

, checkVersion CabalSpecV2_0
(not (null (subLibraries pkg))) $
Expand All @@ -1205,7 +1205,7 @@ checkCabalVersion pkg =
(any (not.null.reexportedModules) (allLibraries pkg)) $
PackageDistInexcusable $
"To use the 'reexported-module' field the package needs to specify "
++ "at least 'cabal-version: >= 1.22'."
++ "at least 'cabal-version: 1.22'."

-- check use of thinning and renaming
, checkVersion CabalSpecV2_0 usesBackpackIncludes $
Expand All @@ -1218,7 +1218,7 @@ checkCabalVersion pkg =
-- Just a warning, because this won't break on old Cabal versions.
PackageDistSuspiciousWarn $
"To use the 'extra-framework-dirs' field the package needs to specify"
++ " at least 'cabal-version: >= 1.24'."
++ " at least 'cabal-version: 1.24'."

-- check use of default-extensions field
-- don't need to do the equivalent check for other-extensions
Expand Down Expand Up @@ -1292,7 +1292,7 @@ checkCabalVersion pkg =
&& isNothing (setupBuildInfo pkg)
&& buildType pkg == Custom) $
PackageBuildWarning $
"Packages using 'cabal-version: >= 1.24' with 'build-type: Custom' "
"Packages using 'cabal-version: 1.24' with 'build-type: Custom' "
++ "must use a 'custom-setup' section with a 'setup-depends' field "
++ "that specifies the dependencies of the Setup.hs script itself. "
++ "The 'setup-depends' field uses the same syntax as 'build-depends', "
Expand All @@ -1303,7 +1303,7 @@ checkCabalVersion pkg =
&& buildType pkg == Custom) $
PackageDistSuspiciousWarn $
"From version 1.24 cabal supports specifying explicit dependencies "
++ "for Custom setup scripts. Consider using cabal-version >= 1.24 and "
++ "for Custom setup scripts. Consider using 'cabal-version: 1.24' and "
++ "adding a 'custom-setup' section with a 'setup-depends' field "
++ "that specifies the dependencies of the Setup.hs script itself. "
++ "The 'setup-depends' field uses the same syntax as 'build-depends', "
Expand Down

0 comments on commit 2116671

Please sign in to comment.