This repository has been archived by the owner on Dec 31, 2017. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 2
/
.travis.yml
60 lines (54 loc) · 2.48 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
# NB: don't set `language: haskell` here
# The following enables several GHC versions to be tested; often it's enough to test only against
# the last release in a major GHC version. Feel free to omit lines listings versions you don't
# need/want testing for.
env:
- CABALVER=1.18 GHCVER=7.6.3 LLVMVER=3.5
- CABALVER=1.18 GHCVER=7.8.4 LLVMVER=3.5
- CABALVER=1.22 GHCVER=7.10.1 LLVMVER=3.5
- CABALVER=1.22 GHCVER=7.10.2 LLVMVER=3.5
# - CABALVER=head GHCVER=head # see section about GHC HEAD snapshots
# Note: the distinction between `before_install` and `install` is not important.
before_install:
- travis_retry sudo apt-get purge -y -qq libllvm3.4 llvm-3.4
- travis_retry sudo add-apt-repository -y ppa:hvr/ghc
- travis_retry sudo apt-get update
- travis_retry sudo apt-get install cabal-install-$CABALVER ghc-$GHCVER # see note about happy/alex
- export PATH=/opt/ghc/$GHCVER/bin:/opt/cabal/$CABALVER/bin:$PATH:$HOME/.cabal/bin:$PATH
- |
if [ $GHCVER = "head" ] || [ ${GHCVER%.*} = "7.8" ] || [ ${GHCVER%.*} = "7.10" ]; then
travis_retry sudo apt-get install happy-1.19.4 alex-3.1.3
export PATH=/opt/alex/3.1.3/bin:/opt/happy/1.19.4/bin:$PATH
else
travis_retry sudo apt-get install happy alex
fi
# update gcc and g++
- gcc --version
- g++ --version
- sudo add-apt-repository -y ppa:ubuntu-toolchain-r/test
- sudo apt-get update -qq
- sudo apt-get install -qq g++-4.8 gcc-4.8
- gcc --version
- g++ --version
- sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-4.8 90
- sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-4.8 90
- gcc --version
- g++ --version
# update llvm
- wget -O - http://llvm.org/apt/llvm-snapshot.gpg.key|sudo apt-key add -
- travis_retry sudo add-apt-repository "deb http://llvm.org/apt/precise/ llvm-toolchain-precise main"
- travis_retry sudo add-apt-repository "deb http://llvm.org/apt/precise/ llvm-toolchain-precise-$LLVMVER main"
- travis_retry sudo apt-get update
- sudo apt-get install libedit-dev -y
- sudo apt-get install -y llvm-$LLVMVER llvm-$LLVMVER-dev
#- sudo ln -s /usr/bin/opt-$LLVMVER /usr/bin/opt
- export PATH="/usr/bin:$PATH"
install:
- cabal --version
- echo "$(ghc --version) [$(ghc --print-project-git-commit-id 2> /dev/null || echo '?')]"
- travis_retry cabal update
- travis_retry cabal install -j4 --only-dependencies
# Here starts the actual work to be performed for the package under test; any command which exits
# with a non-zero exit code causes the build to fail.
script:
- cabal install