-
Notifications
You must be signed in to change notification settings - Fork 3
/
.travis.yml
53 lines (53 loc) · 1.88 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
language: cpp
compiler:
- gcc
# - clang
before_install:
- sudo apt-get update -qq
- sudo apt-get install -qq
install:
# install gcc-4.8 with c++11 support: https://github.com/travis-ci-tester/travis-test-gcc-cxx-11
- sudo add-apt-repository ppa:ubuntu-toolchain-r/test -y
- sudo apt-get update
- sudo apt-get install g++-4.8
- sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-4.8 90
- sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-4.8 90
# https://github.com/travis-ci-tester/travis-test-clang-cxx-11
- sudo apt-get install libstdc++-4.8-dev
# Install newer boost compatible with gcc 4.8.
- wget --no-verbose --output-document=boost-trunk.tar.bz2 http://sourceforge.net/projects/boost/files/boost/1.55.0/boost_1_55_0.tar.bz2/download
- export BOOST_ROOT="$TRAVIS_BUILD_DIR/../boost-trunk"
- export CMAKE_MODULE_PATH="$BOOST_ROOT"
- mkdir -p $BOOST_ROOT
- tar jxf boost-trunk.tar.bz2 --strip-components=1 -C $BOOST_ROOT
- (cd $BOOST_ROOT; ./bootstrap.sh --with-libraries=date_time,filesystem,system,iostreams,regex,python,test)
- (cd $BOOST_ROOT; ./b2 threading=multi --prefix=$BOOST_ROOT -d0 install)
# install cmake
- CMAKE_VERSION="3.0.0"
- wget "http://www.cmake.org/files/v3.0/cmake-${CMAKE_VERSION}.tar.gz"
- openssl sha1 "cmake-${CMAKE_VERSION}.tar.gz"
- tar xf "cmake-${CMAKE_VERSION}.tar.gz"
- cd "cmake-${CMAKE_VERSION}"
- ./bootstrap --prefix=~
- make
- make install
- export PATH="~/bin:${PATH}"
- cd ..
# verify installed versions
- which cmake
- cmake --version
- which g++
- g++ -v
# - which clang
# - clang -v
# Instal dependencies.
- sudo apt-get install libboost-dev libboost-regex-dev
# Install grako.
- pip install -q --user grako==3.3.0
script:
- mkdir build
- cd build
- ~/bin/cmake .. -DBOOST_ROOT=$BOOST_ROOT -DCMAKE_INSTALL_PREFIX:PATH=~
- make
- make test
- make install