CI: cmake build type handling explicit for every build
[marnav.git] / .travis.yml
blob6cafd0b0cd439d34319843d995a5dee442c15596
1 language: c++
2 sudo: false
4 git:
5   depth: 10
6   submodules: false
8 matrix:
9   include:
10     - os: linux
11       env: COMPILER=g++-4.9 CMAKE_BUILD_TYPE=Debug
12       compiler: gcc
13       addons:
14         apt:
15           sources:
16           - ubuntu-toolchain-r-test
17           packages:
18           - gcc-4.9
19           - g++-4.9
21     - os: linux
22       env: COMPILER=g++-4.9 CMAKE_BUILD_TYPE=Release
23       compiler: gcc
24       addons:
25         apt:
26           sources:
27           - ubuntu-toolchain-r-test
28           packages:
29           - gcc-4.9
30           - g++-4.9
32     - os: linux
33       env: COMPILER=g++-5 CMAKE_BUILD_TYPE=Debug
34       compiler: gcc
35       addons:
36         apt:
37           sources:
38           - ubuntu-toolchain-r-test
39           packages:
40           - gcc-5
41           - g++-5
43     - os: linux
44       env: COMPILER=clang++-3.6 CMAKE_BUILD_TYPE=Debug
45       compiler: clang
46       addons:
47         apt:
48           sources:
49           - ubuntu-toolchain-r-test
50           - llvm-toolchain-precise-3.6
51           packages:
52           - clang-3.6
54     - os: linux
55       env: COMPILER=clang++-3.7 CMAKE_BUILD_TYPE=Debug
56       compiler: clang
57       addons:
58         apt:
59           sources:
60           - ubuntu-toolchain-r-test
61           - llvm-toolchain-precise-3.7
62           packages:
63           - clang-3.7
65 install:
66   # install a recent cmake
67   - wget http://www.cmake.org/files/v3.2/cmake-3.2.3-Linux-x86_64.tar.gz
68   - tar -xf cmake-3.2.3-Linux-x86_64.tar.gz
69   - rm -f cmake-3.2.3-Linux-x86_64.tar.gz
70   - export PATH=${PWD}/cmake-3.2.3-Linux-x86_64/bin:${PATH}
72 before_script:
73   - mkdir build
74   - cd build
75   - ${COMPILER} --version
76   - CXX=${COMPILER} cmake -DCMAKE_BUILD_TYPE=${CMAKE_BUILD_TYPE} ..
78 script:
79   - make
80   - make unittest
81   - make test