-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy path.travis.yml
More file actions
56 lines (50 loc) · 1.66 KB
/
.travis.yml
File metadata and controls
56 lines (50 loc) · 1.66 KB
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
language: cpp
cache:
directories:
- $HOME/cache
before_script:
#gcc-6 from cache
- cd $HOME/cache
- sudo cp -r $HOME/cache/archives /var/cache/apt | true
- sudo add-apt-repository ppa:ubuntu-toolchain-r/test -y
- sudo apt-get update
- sudo apt-get install g++-6
- sudo cp -r /var/cache/apt/archives $HOME/cache && sudo rm -rf $HOME/cache/archives/lock | true
- sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-6 90
- sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-6 90
#cmake 3.0 from cache
- cd $HOME/cache
- wget --no-verbose --no-clobber http://www.cmake.org/files/v3.0/cmake-3.0.0.tar.gz
- tar xf cmake-3.0.0.tar.gz
- cd cmake-3.0.0
- 'if [ ! -f cmake-3 ]; then
./bootstrap --prefix=~;
cmake;
echo > cmake-3;
fi'
- sudo make install;
- export PATH="~/bin:${PATH}"
#boost 1.63 from cache
- cd $HOME/cache
- wget --no-verbose --no-clobber http://sourceforge.net/projects/boost/files/boost/1.63.0/boost_1_63_0.tar.bz2/download
- 'if [ ! -f boost_1_63_0/boost-163 ]; then
tar jfx download;
fi'
- cd boost_1_63_0
- 'if [ ! -f boost-163 ]; then
./bootstrap.sh;
./b2 stage;
echo > boost-163;
fi'
#cd build dir
- cd $TRAVIS_BUILD_DIR
script:
- mkdir build_gcc
- cd build_gcc
- cmake .. -DBOOST_ROOT=$HOME/cache/boost_1_63_0 -DUNIT_TESTS=ON
- make
- cd ..
- mkdir build_gcc_static
- cd build_gcc_static
- cmake .. -DBOOST_ROOT=$HOME/cache/boost_1_63_0 -DBUILD_SHARED_LIBS=OFF -DUNIT_TESTS=ON
- make