-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.travis.yml
45 lines (45 loc) · 1.5 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
language: cpp
dist: trusty
env: COMPILER=g++-7
compiler: gcc
git:
depth: 1
addons:
apt:
update: true
sources:
- sourceline: 'ppa:mhier/libboost-latest'
- ubuntu-toolchain-r-test
packages:
- g++-7
# Version number may need to be incremented if the boost ppa is updated.
# If there are issues installing boost, check ppa:mhier/libboost-latest
# for what the version number here should be.
- boost1.68
install:
## Install CMake 3.13.2.
- DEPS_DIR="${TRAVIS_BUILD_DIR}/deps"
- mkdir ${DEPS_DIR}
- cd ${DEPS_DIR}
- travis_retry wget https://github.com/Kitware/CMake/releases/download/v3.13.2/cmake-3.13.2-Linux-x86_64.tar.gz
- echo "6370de82999baafc2dbbf0eda23007d93f78d0c3afda8434a646518915ca0846 cmake-3.13.2-Linux-x86_64.tar.gz" > cmake_sha256.txt
- sha256sum -c cmake_sha256.txt
- tar -xzf cmake-3.13.2-Linux-x86_64.tar.gz
- mv cmake-3.13.2-Linux-x86_64 cmake-install
- PATH=${DEPS_DIR}/cmake-install:${DEPS_DIR}/cmake-install/bin:$PATH
- cd ${TRAVIS_BUILD_DIR}
script:
# Build debug version.
- DEBUG_BUILD_DIR="${TRAVIS_BUILD_DIR}/build_debug"
- mkdir ${DEBUG_BUILD_DIR}
- cd ${DEBUG_BUILD_DIR}
- cmake -DCMAKE_BUILD_TYPE=Debug ${TRAVIS_BUILD_DIR}
- make # build
- make check # run tests
# Build release version.
- RELEASE_BUILD_DIR="${TRAVIS_BUILD_DIR}/build_release"
- mkdir ${RELEASE_BUILD_DIR}
- cd ${RELEASE_BUILD_DIR}
- cmake -DCMAKE_BUILD_TYPE=Release ${TRAVIS_BUILD_DIR}
- make # build
- make check # run tests