forked from esa/pagmo
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
51 lines (45 loc) · 2.25 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
language: cpp
compiler:
# - gcc
- clang
before_install:
# Get GCC 4.9.2 (too memory intensive so currently deactivated)
- if [ "$CXX" == "g++" ]; then wget https://github.com/Viq111/travis-container-packets/releases/download/gcc-4.9.2/gcc.tar.bz2; fi
- if [ "$CXX" == "g++" ]; then tar -xjf gcc.tar.bz2; fi
- if [ "$CXX" == "g++" ]; then rm gcc.tar.bz2; fi
- if [ "$CXX" == "g++" ]; then export PATH=$(pwd)/gcc/bin:$PATH; fi
- if [ "$CXX" == "g++" ]; then export LIBRARY_PATH=$(pwd)/gcc/lib64:$LIBRARY_PATH; fi
- if [ "$CXX" == "g++" ]; then export LD_LIBRARY_PATH=$(pwd)/gcc/lib64:$LD_LIBRARY_PATH; fi
- if [ "$CXX" == "g++" ]; then export CPLUS_INCLUDE_PATH=$(pwd)/gcc/include/c++/4.9.2:$CPLUS_INCLUDE_PATH; fi
# Get clang 3.4 (http://gotoanswer.stanford.edu/?q=Travis+CI+with+Clang+3.4+and+C%2B%2B11)
# necessary as the VM clang links tp old libstdc++
- if [ "$CXX" == "clang++" ]; then sudo add-apt-repository --yes ppa:ubuntu-toolchain-r/test; fi
- if [ "$CXX" == "clang++" ]; then sudo add-apt-repository --yes ppa:h-rayflood/llvm; fi
- if [ "$CXX" == "clang++" ]; then sudo apt-get -qq update; fi
- if [ "$CXX" == "clang++" ]; then sudo apt-get -qq install libstdc++-4.8-dev clang-3.4; fi
- if [ "$CXX" == "clang++" ]; then export CXX="clang++-3.4"; fi
- if [ "$CXX" == "clang++" ]; then export CC= "clang++-3.4"; fi
# Get CMake 3.1
- wget https://github.com/Viq111/travis-container-packets/releases/download/cmake-3.1.2/cmake.tar.bz2
- tar -xjf cmake.tar.bz2
- rm cmake.tar.bz2
- export PATH=$(pwd)/cmake/bin:$PATH
install:
# Get boost
- wget https://github.com/Viq111/travis-container-packets/releases/download/boost-1.57.0/boost.tar.bz2
- tar -xjf boost.tar.bz2
- rm boost.tar.bz2
- export BOOST_ROOT=$(pwd)/boost
- pip install --user ipyparallel
script:
- mkdir build
- cd build
- cmake .. -DBUILD_PYGMO="ON" -DBUILD_EXAMPLES="ON" -DENABLE_TESTS="ON" -DPYTHON_MODULES_DIR="~/local/python" -DCMAKE_INSTALL_PREFIX="~/local"
- make -j4
- make test
- make install
- export PYTHONPATH=~/local/python
- export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:~/local/lib:${PWD%/build}/boost/lib
- python -c "from PyGMO import test; test.run_full_test_suite()"
after_success:
- python -c "import PyGMO; print(PyGMO.__version__)"