/
.travis.yml
68 lines (62 loc) · 1.49 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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
sudo: false
language: c++
dist: trusty
matrix:
include:
- os: linux
compiler: g++
env: COMPILER_VERSION=4
addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- cmake
- libboost-dev
- os: osx
compiler: clang++
addons:
apt:
packages:
- cmake
- libboost-dev
- os: linux
compiler: g++
env: COMPILER_VERSION=5
addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- g++-5
- cmake
- libboost-dev
- os: linux
compiler: g++
env: COMPILER_VERSION=6
addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- g++-6
- cmake
- libboost-dev
before_install:
- if [ "${COMPILER_VERSION}" == "4" ]; then export CXX=g++; fi
- if [ "${COMPILER_VERSION}" == "5" ]; then export CXX=g++-5; fi
- if [ "${COMPILER_VERSION}" == "6" ]; then export CXX=g++-6; fi
install:
- git clone https://github.com/google/googletest googletest
- mkdir -p gtest
- cd gtest
- export GTEST_LIBRARY_PATH=$(pwd)
- cmake -D CMAKE_INSTALL_PREFIX:PATH=$(pwd) ../googletest
- make && make install
- cd -
- export CMAKE_OPTIONS="$CMAKE_OPTIONS -DGTEST_ROOT=${GTEST_LIBRARY_PATH}"
script:
- ${CXX} --version
- cmake ${CMAKE_OPTIONS} .
- make VERBOSE=1 result-test-exe
- ./result-test-exe