diff --git a/.travis.yml b/.travis.yml index e8f5a852..0d0c11ec 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,3 +1,10 @@ +# This is the complex Travis configuration, which is intended for use +# on open source libraries which need compatibility across multiple GHC +# versions, must work with cabal-install, and should be +# cross-platform. For more information and other options, see: +# +# https://docs.haskellstack.org/en/stable/travis_ci/ +# # Copy these contents into the root directory of your Github project in a file # named .travis.yml @@ -60,35 +67,35 @@ matrix: # variable, such as using --stack-yaml to point to a different file. - env: BUILD=stack ARGS="" compiler: ": #stack default" - addons: {apt: {packages: [ghc-7.10.3], sources: [hvr-ghc]}} + addons: {apt: {packages: [libgmp-dev]}} - env: BUILD=stack ARGS="--resolver lts-2" compiler: ": #stack 7.8.4" - addons: {apt: {packages: [ghc-7.8.4], sources: [hvr-ghc]}} + addons: {apt: {packages: [libgmp-dev]}} - env: BUILD=stack ARGS="--resolver lts-3" compiler: ": #stack 7.10.2" - addons: {apt: {packages: [ghc-7.10.2], sources: [hvr-ghc]}} + addons: {apt: {packages: [libgmp-dev]}} - env: BUILD=stack ARGS="--resolver lts-6" compiler: ": #stack 7.10.3" - addons: {apt: {packages: [ghc-7.10.3], sources: [hvr-ghc]}} + addons: {apt: {packages: [libgmp-dev]}} - env: BUILD=stack ARGS="--resolver lts-7" compiler: ": #stack 8.0.1" - addons: {apt: {packages: [ghc-8.0.1], sources: [hvr-ghc]}} + addons: {apt: {packages: [libgmp-dev]}} # Nightly builds are allowed to fail - env: BUILD=stack ARGS="--resolver nightly" compiler: ": #stack nightly" - addons: {apt: {packages: [libgmp,libgmp-dev]}} + addons: {apt: {packages: [libgmp-dev]}} # Build on OS X in addition to Linux - env: BUILD=stack ARGS="" compiler: ": #stack default osx" os: osx - # Doesn't include hfsevents + # Travis includes an OS X which is incompatible with GHC 7.8.4 #- env: BUILD=stack ARGS="--resolver lts-2" # compiler: ": #stack 7.8.4 osx" # os: osx @@ -142,9 +149,6 @@ before_install: echo 'jobs: $ncpus' >> $HOME/.cabal/config fi -# Get the list of packages from the stack.yaml file -- PACKAGES=$(stack --install-ghc query locals | grep '^ *path' | sed 's@^ *path:@@') - install: - echo "$(ghc --version) [$(ghc --print-project-git-commit-id 2> /dev/null || echo '?')]" - if [ -f configure.ac ]; then autoreconf -i; fi @@ -157,6 +161,10 @@ install: cabal) cabal --version travis_retry cabal update + + # Get the list of packages from the stack.yaml file + PACKAGES=$(stack --install-ghc query locals | grep '^ *path' | sed 's@^ *path:@@') + cabal install --only-dependencies --enable-tests --enable-benchmarks --force-reinstalls --ghc-options=-O0 --reorder-goals --max-backjumps=-1 $CABALARGS $PACKAGES ;; esac