-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy path.travis.yml
72 lines (69 loc) · 1.56 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
69
70
71
72
language: cpp
dist: trusty
matrix:
fast_finish: true
include:
- name: linux gcc
os: linux
compiler: gcc
env: DO_COVERAGE=true
addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- g++-4.9
- libboost-regex-dev
- name: linux clang
os: linux
compiler: clang
addons:
apt:
packages:
- libboost-regex-dev
- name: osx gcc
os: osx
compiler: gcc
osx_image: xcode9.4
addons:
homebrew:
packages:
- gcc@6
update: true
- name: osx clang
os: osx
compiler: clang
osx_image: xcode9.4
before_install:
- |
if [[ "$DO_COVERAGE" == "true" ]] ; then
export CMAKE_ARGS="-DCMAKE_CXX_FLAGS=--coverage -DCMAKE_C_FLAGS=--coverage"
pip install --user codecov
fi
- |
if [[ "$TRAVIS_OS_NAME" == "linux" ]] ; then
if [[ "$TRAVIS_COMPILER" == "gcc" ]] ; then
export CC=gcc-4.9
export CXX=g++-4.9
fi
fi
- |
if [[ "$TRAVIS_OS_NAME" == "osx" ]] ; then
if [[ "$TRAVIS_COMPILER" == "gcc" ]] ; then
export CC=gcc-6
export CXX=g++-6
fi
fi
script:
- cd $TRAVIS_BUILD_DIR
- ./scripts/check-whitespaces.py
- mkdir -p build
- cd build
- cmake -DCMAKE_BUILD_TYPE=debug $CMAKE_ARGS ..
- make
- ctest -L cfiles --output-on-failure
- |
if [[ "$DO_COVERAGE" == "true" ]] ; then
cd $TRAVIS_BUILD_DIR
codecov --gcov-exec=gcov-4.9
fi