Skip to content

Commit

Permalink
attempt to get travis to run multiple GHCs #82
Browse files Browse the repository at this point in the history
  • Loading branch information
etrepum committed Jun 23, 2015
1 parent 78f9c33 commit 0559736
Show file tree
Hide file tree
Showing 2 changed files with 47 additions and 21 deletions.
32 changes: 27 additions & 5 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,31 @@
language: haskell
ghc:
- 7.6
install:
language: c
sudo: false
addons:
apt:
sources:
- hvr-ghc
packages:
- ghc-7.6.3
- ghc-7.8.4
- ghc-7.10.1
- cabal-install-1.22
env:
global:
- CABALVER=1.22
matrix:
- GHCVER=7.6.3
- GHCVER=7.8.4
- GHCVER=7.10.1
cache:
directories:
- '$HOME/.ghc'
- '$HOME/.cabal'
before_install:
- './_test/bootstrap.sh'
install:
- true
script:
- '( export PATH=/opt/hp-2013.2.0.0/bin:$PATH; runhaskell ./_test/check-exercises.hs )'
- 'export PATH=/opt/cabal/$CABALVER/bin:/opt/ghc/$GHCVER/bin:$PATH'
- 'runhaskell -Wall ./_test/check-exercises.hs'
- './bin/fetch-configlet'
- './bin/configlet .'
36 changes: 20 additions & 16 deletions _test/bootstrap.sh
Original file line number Diff line number Diff line change
@@ -1,21 +1,25 @@
#!/bin/bash
# This installs a Haskell platform to PREFIX=/opt/hp-2013.2.0.0
# This installs a the prerequisites for a given GHC/Cabal config
set -x
set -e
HP_VER=2013.2.0.0
HP_URL=https://github.com/etrepum/travis-haskell/releases/download/${HP_VER}/hp-${HP_VER}.tar.bz2
PREFIX=/opt/hp-${HP_VER}
sudo apt-get update
sudo apt-get -y install git gcc make autoconf libtool zlib1g-dev \
libncurses-dev libgmp-dev
if [ ! -e "/usr/lib/libgmp.so.3" ]; then
sudo ln -s /usr/lib/x86_64-linux-gnu/libgmp.so.10 /usr/lib/libgmp.so.3
if [ ! -z "$GHCVER" ]; then
export PATH=/opt/ghc/${GHCVER}/bin:$PATH
fi
if [ ! -e "/usr/lib/libgmp.so" ]; then
sudo ln -s /usr/lib/x86_64-linux-gnu/libgmp.so.10 /usr/lib/libgmp.so
if [ ! -z "$CABALVER" ]; then
export PATH=/opt/cabal/${CABALVER}/bin:$PATH
fi
if [ ! -e "${PREFIX}" ]; then
( cd /
curl -L "${HP_URL}" | sudo tar jxf - )
fi
sudo chmod ugo+rX -R "${PREFIX}"
cabal update
# This is a fairly minimal set
cabal install \
primitive \
random \
tf-random \
HUnit \
QuickCheck \
split \
text \
bytestring \
attoparsec \
vector \
parallel \
stm

0 comments on commit 0559736

Please sign in to comment.