2016-08-03 09:35:01 +00:00
|
|
|
language: c
|
2015-08-05 04:20:55 +00:00
|
|
|
sudo: false
|
|
|
|
|
|
|
|
cache:
|
|
|
|
apt: true
|
|
|
|
directories:
|
2016-08-03 09:35:01 +00:00
|
|
|
- $HOME/.stack
|
|
|
|
- $HOME/.ghc-mod
|
2015-08-05 04:20:55 +00:00
|
|
|
|
2016-08-03 09:35:01 +00:00
|
|
|
addons:
|
|
|
|
apt:
|
|
|
|
packages:
|
|
|
|
- libfcgi-dev
|
|
|
|
- libgmp-dev
|
2015-08-05 04:20:55 +00:00
|
|
|
|
2015-08-18 03:45:13 +00:00
|
|
|
before_install:
|
2016-08-03 09:35:01 +00:00
|
|
|
- unset CC
|
|
|
|
- mkdir -p ~/.local/bin
|
|
|
|
- export PATH=$HOME/.local/bin:$PATH
|
|
|
|
- travis_retry curl -L https://www.stackage.org/stack/linux-x86_64 | tar xz --wildcards --strip-components=1 -C ~/.local/bin '*/stack'
|
2015-08-18 03:45:13 +00:00
|
|
|
- stack --version
|
|
|
|
|
2014-01-08 07:10:26 +00:00
|
|
|
install:
|
2016-08-03 13:10:53 +00:00
|
|
|
# - git clone --depth=1 https://github.com/DanielG/cabal-helper.git
|
2016-08-03 13:43:48 +00:00
|
|
|
- stack --no-terminal setup --resolver=ghc-$GHCVER
|
|
|
|
- stack --no-terminal install cabal-install --resolver=$RES
|
2014-05-01 01:07:10 +00:00
|
|
|
- cabal update
|
2016-08-03 13:43:48 +00:00
|
|
|
- stack --no-terminal install happy --resolver=$RES
|
2016-08-03 13:10:53 +00:00
|
|
|
# - stack init --ignore-subdirs --resolver=ghc-$GHCVER ./ cabal-helper/
|
|
|
|
# - stack init --ignore-subdirs --resolver=ghc-$GHCVER ./
|
|
|
|
- |
|
|
|
|
resf="ghc-$GHCVER.yaml"
|
|
|
|
echo "resolver: ghc-$GHCVER" > "$resf"
|
2016-08-03 13:43:48 +00:00
|
|
|
stack --no-terminal solver --update-config --stack-yaml="$resf"
|
2016-08-03 13:10:53 +00:00
|
|
|
sed -i 's/^resolver:/compiler:/;s/^extra-deps:/packages:/' "$resf"
|
|
|
|
echo "resolver: { name: 'ghc-$GHCVER', location: './$resf' }" > stack.yaml
|
|
|
|
ir=$( stack path --snapshot-install-root )
|
|
|
|
ls -d ${ir%/custom-ghc-*}/custom-ghc-* | grep -v "${ir%/*}" | while read i; do
|
|
|
|
rm -rfv "$i"
|
|
|
|
done
|
|
|
|
|
2014-01-08 07:10:26 +00:00
|
|
|
|
|
|
|
script:
|
2014-07-02 17:19:36 +00:00
|
|
|
- cabal check
|
2016-08-03 13:43:48 +00:00
|
|
|
- stack --no-terminal build --test --no-run-tests
|
|
|
|
- stack --no-terminal test ghc-mod:spec
|
2014-01-08 07:10:26 +00:00
|
|
|
|
|
|
|
matrix:
|
2016-08-03 09:35:01 +00:00
|
|
|
matrix:
|
|
|
|
include:
|
|
|
|
- env: GHCVER=7.8.4 RES=lts-2.22
|
|
|
|
compiler: ': #GHC 7.8.4'
|
|
|
|
- env: GHCVER=7.10.3 RES=lts-6.9
|
|
|
|
compiler: ': #GHC 7.10.3'
|
|
|
|
- env: GHCVER=8.0.1 RES=nightly-2016-08-01
|
|
|
|
compiler: ': #GHC 8.0.1'
|