Skip to content
Permalink

Comparing changes

This is a direct comparison between two commits made in this repository or its related repositories. View the default comparison for this range or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: haskell/cabal
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: ff003fad30f1da683ab71532d26a97e1e8930f70
Choose a base ref
..
head repository: haskell/cabal
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 686173c5519dafd04cdc0d538703ca9014771e07
Choose a head ref
Showing with 33 additions and 7 deletions.
  1. +1 −1 Cabal/Distribution/PackageDescription/Check.hs
  2. +1 −1 appveyor.yml
  3. +27 −3 cabal-install/Distribution/Client/ProjectConfig/Legacy.hs
  4. +2 −0 cabal-install/changelog
  5. +2 −2 travis-script.sh
2 changes: 1 addition & 1 deletion Cabal/Distribution/PackageDescription/Check.hs
Original file line number Diff line number Diff line change
@@ -801,7 +801,7 @@ checkGhcOptions pkg =
"'ghc-options: --make' is never needed. Cabal uses this automatically."

, checkFlags ["-main-is"] $
PackageDistSuspicious $
PackageDistSuspiciousWarn $
"'ghc-options: -main-is' is not portable."

, checkNonTestAndBenchmarkFlags ["-O0", "-Onot"] $
2 changes: 1 addition & 1 deletion appveyor.yml
Original file line number Diff line number Diff line change
@@ -53,7 +53,7 @@ build_script:
- cd ..\cabal-testsuite
- dist\build\cabal-tests\cabal-tests.exe -j3 --skip-setup-tests --with-cabal=..\cabal-install\dist\build\cabal\cabal.exe
- cd ..\cabal-install
- ..\cabal test unit-tests --show-details=streaming --test-option="--pattern=! /FileMonitor/" --test-option=--hide-successes
- ..\cabal test unit-tests --show-details=streaming --test-option=--pattern=!FileMonitor --test-option=--hide-successes
- ..\cabal test integration-tests2 --show-details=streaming --test-option=--hide-successes
- ..\cabal test solver-quickcheck --show-details=streaming --test-option=--hide-successes --test-option=--quickcheck-tests=1000
- ..\cabal test memory-usage-tests --show-details=streaming
30 changes: 27 additions & 3 deletions cabal-install/Distribution/Client/ProjectConfig/Legacy.hs
Original file line number Diff line number Diff line change
@@ -166,10 +166,34 @@ commandLineFlagsToProjectConfig globalFlags configFlags configExFlags
projectConfigShared = convertLegacyAllPackageFlags
globalFlags configFlags
configExFlags installFlags,
projectConfigLocalPackages = convertLegacyPerPackageFlags
configFlags installFlags haddockFlags
projectConfigLocalPackages = localConfig,
projectConfigAllPackages = allConfig
}

where (localConfig, allConfig) = splitConfig
(convertLegacyPerPackageFlags
configFlags installFlags haddockFlags)
-- split the package config (from command line arguments) into
-- those applied to all packages and those to local only.
--
-- for now we will just copy over the ProgramPaths/Args/Extra into
-- the AllPackages. The LocalPackages do not inherit them from
-- AllPackages, and as such need to retain them.
--
-- The general decision rule for what to put into allConfig
-- into localConfig is the following:
--
-- - anything that is host/toolchain/env specific should be applied
-- to all packages, as packagesets have to be host/toolchain/env
-- consistent.
-- - anything else should be in the local config and could potentially
-- be lifted into all-packages vial the `package *` cabal.project
-- section.
--
splitConfig :: PackageConfig -> (PackageConfig, PackageConfig)
splitConfig pc = (pc
, mempty { packageConfigProgramPaths = packageConfigProgramPaths pc
, packageConfigProgramArgs = packageConfigProgramArgs pc
, packageConfigProgramPathExtra = packageConfigProgramPathExtra pc })

-- | Convert from the types currently used for the user-wide @~/.cabal/config@
-- file into the 'ProjectConfig' type.
2 changes: 2 additions & 0 deletions cabal-install/changelog
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
-*-change-log-*-

2.2.0.0 (current development version)
* '--with-PROG' and '--PROG-options' are applied to all packages
and not local packages only (#5019).
* Completed the 'new-update' command (#4809), which respects nix-style
cabal.project(.local) files and allows to update from
multiple repositories when using overlays.
4 changes: 2 additions & 2 deletions travis-script.sh
Original file line number Diff line number Diff line change
@@ -110,7 +110,7 @@ if [ "x$CABAL_INSTALL_ONLY" != "xYES" ] ; then
fi

# Check for package warnings
(cd Cabal && timed cabal check) || exit $?
# (cd Cabal && timed cabal check) || exit $?
fi

unset CABAL_BUILDDIR
@@ -175,7 +175,7 @@ timed ${CABAL_INSTALL_BDIR}/build/cabal/cabal update
# Big tests
(cd cabal-testsuite && timed ${CABAL_TESTSUITE_BDIR}/build/cabal-tests/cabal-tests --builddir=${CABAL_TESTSUITE_BDIR} -j3 --skip-setup-tests --with-cabal ${CABAL_INSTALL_BDIR}/build/cabal/cabal --with-hackage-repo-tool ${HACKAGE_REPO_TOOL_BDIR}/build/hackage-repo-tool/hackage-repo-tool $TEST_OPTIONS) || exit $?

(cd cabal-install && timed cabal check) || exit $?
# (cd cabal-install && timed cabal check) || exit $?

if [ "x$TEST_SOLVER_BENCHMARKS" = "xYES" ]; then
timed cabal new-build $jobs solver-benchmarks:hackage-benchmark solver-benchmarks:unit-tests