diff options
Diffstat (limited to '.travis.yml')
-rw-r--r-- | .travis.yml | 29 |
1 files changed, 20 insertions, 9 deletions
diff --git a/.travis.yml b/.travis.yml index 74b2d0da..d3f4711f 100644 --- a/.travis.yml +++ b/.travis.yml @@ -11,6 +11,7 @@ addons: - qt5-default - qtmultimedia5-dev - valgrind + - g++-8 env: global: @@ -24,7 +25,7 @@ matrix: compiler: gcc - os: linux compiler: gcc - env: [ 'E2EE="-DQuotient_ENABLE_E2EE=ON"' ] + env: [ 'E2EE="-DQuotient_ENABLE_E2EE=ON"', 'UPDATE_API=1' ] - os: linux compiler: clang - os: osx @@ -43,6 +44,12 @@ matrix: before_install: - if [ -f "$(which ninja)" ]; then export CMAKE_ARGS="$CMAKE_ARGS -GNinja"; fi +# The recent GTAD uses std::filesystem that's not available in stock bionic +- | + if [ -n "$UPDATE_API" ]; then + export CC=gcc-8 CXX=g++-8 + export CMAKE_UPDATE_API_ARGS="-DMATRIX_DOC_PATH=matrix-doc -DGTAD_PATH=gtad/gtad" + fi # RPM spec-style: swallow a command with default parameters into an alias # and add/override parameters further in the code if/as necessary - shopt -s expand_aliases @@ -55,16 +62,20 @@ install: - _cmake_config - _cmake_build --target install - popd -- git clone https://github.com/quotient-im/matrix-doc.git -- git clone --recursive https://github.com/KitsuneRal/gtad.git -- pushd gtad -- cmake $CMAKE_ARGS . -- cmake --build . -- popd + +- | + if [ -n "$UPDATE_API" ]; then + git clone https://github.com/quotient-im/matrix-doc.git + git clone --recursive https://github.com/KitsuneRal/gtad.git + pushd gtad + cmake $CMAKE_ARGS . + cmake --build . + popd + fi before_script: -- _cmake_config -DMATRIX_DOC_PATH="matrix-doc" -DGTAD_PATH="gtad/gtad" $E2EE -- _cmake_build --target update-api +- _cmake_config $CMAKE_UPDATE_API_ARGS $E2EE +- if [ -n "$UPDATE_API" ]; then _cmake_build --target update-api; fi script: - _cmake_build --target install |