Skip to content

Commit

Permalink
use services: docker on travis
Browse files Browse the repository at this point in the history
[av skip]
  • Loading branch information
tkelman committed Nov 28, 2015
1 parent 4d0b1ac commit e3ece76
Showing 1 changed file with 31 additions and 35 deletions.
66 changes: 31 additions & 35 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@ os:
env:
- ARCH="i686"
- ARCH="x86_64"
sudo: required
dist: trusty
services: docker
matrix:
exclude:
- os: osx
Expand All @@ -22,53 +25,46 @@ notifications:
- http://julia.mit.edu:8000/travis-hook
before_install:
- make check-whitespace
- if [ `uname` = "Linux" ]; then
sudo apt-get install jq -y;
- if [ $(uname) = Linux ]; then
contrib/travis_fastfail.sh || exit 1;
BUILDOPTS="-j3 USEGCC=1 LLVM_CONFIG=llvm-config-3.3 VERBOSE=1 USE_BLAS64=0 FORCE_ASSERTIONS=1 STAGE2_DEPS=utf8proc";
for lib in LLVM SUITESPARSE ARPACK BLAS FFTW LAPACK GMP MPFR OPENLIBM; do
export BUILDOPTS="$BUILDOPTS USE_SYSTEM_$lib=1";
done;
sudo add-apt-repository ppa:staticfloat/julia-deps -y;
sudo apt-get update -qq -y;
if [ "$ARCH" = "i686" ]; then
export BUILDOPTS="$BUILDOPTS MARCH=pentium4";
sudo apt-get remove libblas3gf liblapack3gf libarmadillo2 -y;
sudo apt-get install binutils:i386 -y;
sudo apt-get install gcc:i386 g++:i386 make:i386 cpp:i386 g++-4.6:i386 gcc-4.6:i386 libssl-dev:i386 patchelf:i386 gfortran:i386 llvm-3.3-dev:i386 libsuitesparse-dev:i386 libopenblas-dev:i386 libopenblas-base:i386 libblas-dev:i386 liblapack-dev:i386 liblapack3:i386 libarpack2-dev:i386 libarpack2:i386 libfftw3-dev:i386 libgmp-dev:i386 libpcre3-dev:i386 libopenlibm-dev:i386 libmpfr-dev:i386 -y;
else
export JULIA_TEST_MAXRSS_MB="500";
sudo apt-get install patchelf gfortran llvm-3.3-dev libsuitesparse-dev libopenblas-dev liblapack-dev libarpack2-dev libfftw3-dev libgmp-dev libpcre3-dev libopenlibm-dev libmpfr-dev -y;
fi;
elif [ `uname` = "Darwin" ]; then
brew tap staticfloat/julia;
brew rm --force $(brew deps --HEAD julia);
BUILDOPTS="-j3 VERBOSE=1 FORCE_ASSERTIONS=1";
DOCKERRUN="sudo docker run -w /home/julia-$ARCH tkelman/julia32-part2:master";
elif [ $(uname) = Darwin ]; then
brew update;
brew install -v jq;
contrib/travis_fastfail.sh || exit 1;
brew tap staticfloat/julia;
brew rm --force $(brew deps --HEAD julia);
brew install -v --only-dependencies --HEAD julia;
BUILDOPTS="-j3 USECLANG=1 LLVM_CONFIG=$(brew --prefix llvm33-julia)/bin/llvm-config-3.3 VERBOSE=1 USE_BLAS64=0 SUITESPARSE_INC=-I$(brew --prefix suite-sparse-julia)/include FORCE_ASSERTIONS=1 STAGE2_DEPS=utf8proc";
BUILDOPTS="$BUILDOPTS LIBBLAS=-lopenblas LIBBLASNAME=libopenblas LIBLAPACK=-lopenblas LIBLAPACKNAME=libopenblas";
for lib in LLVM SUITESPARSE ARPACK BLAS FFTW LAPACK GMP MPFR PCRE LIBUNWIND LIBGIT2; do
export BUILDOPTS="$BUILDOPTS USE_SYSTEM_$lib=1";
done;
DOCKERRUN="";
export LDFLAGS="-L$(brew --prefix openblas-julia)/lib -L$(brew --prefix suite-sparse-julia)/lib";
export DYLD_FALLBACK_LIBRARY_PATH="/usr/local/lib:/lib:/usr/lib:$(brew --prefix openblas-julia)/lib:$(brew --prefix suite-sparse-julia)/lib:$(brew --prefix arpack-julia)/lib";
make $BUILDOPTS -C contrib -f repackage_system_suitesparse4.make;
fi
script:
- make $BUILDOPTS -C base version_git.jl.phony
- git clone -q git://git.kitenet.net/moreutils
- make $BUILDOPTS NO_GIT=1 JULIA_SYSIMG_BUILD_FLAGS="--output-ji ../usr/lib/julia/sys.ji" prefix=/tmp/julia install | moreutils/ts -s "%.s"
- if [ `uname` = "Darwin" ]; then
for name in suitesparseconfig spqr umfpack colamd cholmod amd suitesparse_wrapper; do
install -pm755 usr/lib/lib${name}*.dylib* /tmp/julia/lib/julia/;
done;
fi
- cd .. && mv julia julia2
- cp /tmp/julia/lib/julia/sys.ji local.ji && /tmp/julia/bin/julia -J local.ji -e 'true' && /tmp/julia/bin/julia-debug -J local.ji -e 'true' && rm local.ji
- /tmp/julia/bin/julia -e 'versioninfo()'
- export JULIA_CPU_CORES=2 && cd /tmp/julia/share/julia/test && /tmp/julia/bin/julia --check-bounds=yes runtests.jl all && /tmp/julia/bin/julia --check-bounds=yes runtests.jl libgit2-online pkg
- cd - && mv julia2 julia
- sudo dmesg
- echo "Ready for packaging..."
- make -C moreutils mispipe
script:
- |
moreutils/mispipe "$DOCKERRUN sh -c \
\"if [ $TRAVIS_PULL_REQUEST = false ]; then git fetch origin $TRAVIS_BRANCH: ; else \
git fetch origin +refs/pull/$TRAVIS_PULL_REQUEST/merge: ; fi && \
git checkout -qf FETCH_HEAD && \
make $BUILDOPTS -C base version_git.jl.phony && \
make $BUILDOPTS NO_GIT=1 JULIA_SYSIMG_BUILD_FLAGS='--output-ji ../usr/lib/julia/sys.ji' prefix=/tmp/julia install && \
if [ $(uname) = Darwin ]; then \
for name in suitesparseconfig spqr umfpack colamd cholmod amd suitesparse_wrapper; do \
install -pm755 usr/lib/lib${name}*.dylib* /tmp/julia/lib/julia/; \
done; \
fi && \
cd .. && rm -rf julia* && \
cp /tmp/julia/lib/julia/sys.ji local.ji && /tmp/julia/bin/julia -J local.ji -e 'true' && /tmp/julia/bin/julia-debug -J local.ji -e 'true' && rm local.ji && \
/tmp/julia/bin/julia -e 'versioninfo()' && \
cd /tmp/julia/share/julia/test && /tmp/julia/bin/julia --check-bounds=yes runtests.jl all && /tmp/julia/bin/julia --check-bounds=yes runtests.jl libgit2-online pkg\" \
" 'moreutils/ts -s "%.s"'
# uncomment the following if failures are suspected to be due to the out-of-memory killer
# - sudo dmesg

0 comments on commit e3ece76

Please sign in to comment.