2019-04-09 15:53:39 +02:00
|
|
|
language: cpp
|
|
|
|
|
sudo: require
|
2019-05-17 14:46:54 +02:00
|
|
|
dist: xenial
|
2019-04-09 15:53:39 +02:00
|
|
|
|
|
|
|
|
common_sources: &all_sources
|
|
|
|
|
- ubuntu-toolchain-r-test
|
|
|
|
|
- llvm-toolchain-trusty
|
2019-05-17 14:46:54 +02:00
|
|
|
|
|
|
|
|
python:
|
|
|
|
|
- 3.7
|
2019-04-09 15:53:39 +02:00
|
|
|
|
|
|
|
|
matrix:
|
|
|
|
|
include:
|
|
|
|
|
- os: linux
|
|
|
|
|
compiler: gcc
|
|
|
|
|
addons: &gcc8
|
|
|
|
|
apt:
|
|
|
|
|
sources: *all_sources
|
2019-10-10 20:13:10 +02:00
|
|
|
packages:
|
2019-04-09 15:53:39 +02:00
|
|
|
- g++-8
|
|
|
|
|
env:
|
|
|
|
|
- MATRIX_EVAL="export CC=gcc-8; export CXX=g++-8;"
|
|
|
|
|
|
|
|
|
|
- os: linux
|
|
|
|
|
compiler: clang
|
|
|
|
|
addons:
|
2019-10-10 20:13:10 +02:00
|
|
|
apt:
|
|
|
|
|
sources: *all_sources
|
|
|
|
|
packages:
|
|
|
|
|
- g++-8
|
|
|
|
|
- clang-6.0
|
2019-04-09 15:53:39 +02:00
|
|
|
env:
|
|
|
|
|
- MATRIX_EVAL="export CC=clang-6.0; export CXX=clang++-6.0;"
|
|
|
|
|
|
2019-04-09 16:04:45 +02:00
|
|
|
before_install:
|
|
|
|
|
# Update compilers
|
|
|
|
|
- eval "${MATRIX_EVAL}"
|
|
|
|
|
- echo "CC=$CC CXX=$CXX"
|
2019-04-11 10:13:28 +02:00
|
|
|
# Install a supported cmake version (>= 3.14)
|
2019-10-10 20:13:10 +02:00
|
|
|
- wget -O cmake.sh https://cmake.org/files/v3.14/cmake-3.14.0-Linux-x86_64.sh
|
2019-04-11 10:13:28 +02:00
|
|
|
- sudo sh cmake.sh --skip-license --exclude-subdir --prefix=/usr/local
|
|
|
|
|
- export PATH=/usr/local/bin:$PATH
|
|
|
|
|
- cmake --version
|
2019-04-09 16:04:45 +02:00
|
|
|
|
2019-04-09 15:53:39 +02:00
|
|
|
script:
|
2019-06-22 13:31:32 +02:00
|
|
|
# unit tests
|
|
|
|
|
- cmake -Htest -Bbuild/test
|
2019-10-24 18:14:58 +02:00
|
|
|
- cmake --build build/test --target test-verbose
|
2019-10-24 15:42:25 +02:00
|
|
|
# build examples
|
2019-10-10 20:13:10 +02:00
|
|
|
- python3 examples/build_all.py
|