|
|
|
|
addons:
|
|
|
|
|
apt:
|
|
|
|
|
packages:
|
|
|
|
|
- g++-4.8
|
|
|
|
|
- libgl1-mesa-dev
|
|
|
|
|
- ninja-build
|
|
|
|
|
- lcov
|
|
|
|
|
|
|
|
|
|
matrix:
|
|
|
|
|
include:
|
|
|
|
|
- language: python
|
|
|
|
|
python: 3.6
|
|
|
|
|
os: linux
|
|
|
|
|
dist: xenial
|
|
|
|
|
compiler: gcc
|
|
|
|
|
env:
|
|
|
|
|
- JOBID=linux-gl
|
|
|
|
|
- TARGET=desktop
|
|
|
|
|
- BUILD_STATIC=OFF
|
|
|
|
|
- LCOV_EXTRA_OPTS="--gcov-tool /usr/bin/gcov-4.8"
|
|
|
|
|
- language: python
|
|
|
|
|
python: 3.6
|
|
|
|
|
os: linux
|
|
|
|
|
dist: xenial
|
|
|
|
|
compiler: gcc
|
|
|
|
|
env:
|
|
|
|
|
- JOBID=linux-gl-static
|
|
|
|
|
- TARGET=desktop
|
|
|
|
|
- BUILD_STATIC=ON
|
|
|
|
|
- LCOV_EXTRA_OPTS="--gcov-tool /usr/bin/gcov-4.8"
|
|
|
|
|
- language: python
|
|
|
|
|
python: 3.6
|
|
|
|
|
os: linux
|
|
|
|
|
dist: xenial
|
|
|
|
|
compiler: gcc
|
|
|
|
|
env:
|
|
|
|
|
- JOBID=linux-gles2
|
|
|
|
|
- TARGET=desktop-gles
|
|
|
|
|
- TARGET_GLES2=ON
|
|
|
|
|
- CMAKE_CXX_FLAGS="--coverage"
|
|
|
|
|
- LCOV_EXTRA_OPTS="--gcov-tool /usr/bin/gcov-4.8"
|
|
|
|
|
addons:
|
|
|
|
|
apt:
|
|
|
|
|
packages:
|
|
|
|
|
- g++-4.8
|
|
|
|
|
- ninja-build
|
|
|
|
|
- lcov
|
|
|
|
|
- libgles2-mesa-dev
|
|
|
|
|
- language: python
|
|
|
|
|
python: 3.6
|
|
|
|
|
os: linux
|
|
|
|
|
dist: xenial
|
|
|
|
|
compiler: gcc
|
|
|
|
|
env:
|
|
|
|
|
- JOBID=linux-gles3
|
|
|
|
|
- TARGET=desktop-gles
|
|
|
|
|
- TARGET_GLES2=OFF
|
|
|
|
|
- CMAKE_CXX_FLAGS="--coverage"
|
|
|
|
|
- LCOV_EXTRA_OPTS="--gcov-tool /usr/bin/gcov-4.8"
|
|
|
|
|
addons:
|
|
|
|
|
apt:
|
|
|
|
|
packages:
|
|
|
|
|
- g++-4.8
|
|
|
|
|
- ninja-build
|
|
|
|
|
- lcov
|
|
|
|
|
- libgles2-mesa-dev
|
|
|
|
|
- language: cpp
|
|
|
|
|
os: osx
|
|
|
|
|
compiler: clang
|
|
|
|
|
env:
|
|
|
|
|
- JOBID=macos-gl
|
|
|
|
|
- TARGET=desktop
|
|
|
|
|
- BUILD_STATIC=OFF
|
|
|
|
|
|
|
|
|
|
notifications:
|
|
|
|
|
webhooks:
|
|
|
|
|
urls:
|
|
|
|
|
- https://webhooks.gitter.im/e/00ec7a9066bb0fec98f3
|
|
|
|
|
on_success: change
|
|
|
|
|
on_failure: always
|
|
|
|
|
on_start: never
|
|
|
|
|
|
|
|
|
|
cache:
|
|
|
|
|
directories:
|
|
|
|
|
- $HOME/swiftshader
|
|
|
|
|
- $HOME/cmake
|
|
|
|
|
- $HOME/pybind11
|
|
|
|
|
|
|
|
|
|
install:
|
|
|
|
|
- if [ "$TRAVIS_OS_NAME" == "linux" ]; then export CXX=g++-4.8; fi
|
|
|
|
|
# Download CMake 3.1.3 to ensure we're still compatible with it (Travis has
|
|
|
|
|
# 3.9 since December 2017). Also, the PATH setting can't be cached, so it's
|
|
|
|
|
# separate (bit me two times already). Android needs CMake 3.7, but
|
|
|
|
|
# https://gitlab.kitware.com/cmake/cmake/issues/17253 is fixed in 3.9.2, so
|
|
|
|
|
# grab that. FindVulkan is since 3.7, in that case just use the system package.
|
|
|
|
|
- if [ "$TRAVIS_OS_NAME" == "linux" ] && [ ! -e "$HOME/cmake/bin" ]; then cd $HOME ; wget -nc --no-check-certificate https://cmake.org/files/v3.1/cmake-3.1.3-Linux-x86_64.tar.gz && mkdir -p cmake && cd cmake && tar --strip-components=1 -xzf ../cmake-3.1.3-Linux-x86_64.tar.gz && cd $TRAVIS_BUILD_DIR ; fi
|
|
|
|
|
- if [ "$TRAVIS_OS_NAME" == "linux" ]; then export PATH=$HOME/cmake/bin:$PATH && cmake --version; fi
|
|
|
|
|
- if [ "$TRAVIS_OS_NAME" == "osx" ]; then HOMEBREW_NO_AUTO_UPDATE=1 brew install ninja; fi
|
|
|
|
|
|
|
|
|
|
# Code coverage of python bindings
|
|
|
|
|
- if [ "$TRAVIS_OS_NAME" == "linux" ] || [ "$TRAVIS_OS_NAME" == "osx" ]; then pip3 install coverage codecov; fi
|
|
|
|
|
|
|
|
|
|
# pybind11 (cached). On macOS the version 2.3.0 needs a brew update, the stale
|
|
|
|
|
# Travis image has just 2.2.4.
|
|
|
|
|
- if [ "$TRAVIS_OS_NAME" == "linux" ] && [ ! -e "$HOME/pybind11/bin" ]; then $TRAVIS_BUILD_DIR/package/ci/setup-pybind11.sh; fi
|
|
|
|
|
- if [ "$TRAVIS_OS_NAME" == "osx" ]; then brew install pybind11; fi
|
|
|
|
|
|
|
|
|
|
# numpy on macOS -- probably because we updated Homebrew to install new pybind
|
|
|
|
|
# (and thus python as well, apparently), the preinstalled numpy is no longer
|
|
|
|
|
# visible.
|
|
|
|
|
- if [ "$TRAVIS_OS_NAME" == "osx" ]; then brew upgrade numpy; fi
|
|
|
|
|
|
|
|
|
|
# SwiftShader on Linux (cached). Taken from Chromium snapshot 587878
|
|
|
|
|
# (swiftshader-bin Arch package).
|
|
|
|
|
- if [ "$TRAVIS_OS_NAME" == "linux" ] && [ "$TARGET" == "desktop-gles" ] && [ ! -e "$HOME/swiftshader/libEGL.so" ]; then cd $HOME ; wget https://ci.magnum.graphics/swiftshader-chromium-587878.tar.gz && mkdir -p swiftshader && cd swiftshader && tar -xzf ../swiftshader-chromium-587878.tar.gz && cd $TRAVIS_BUILD_DIR ; fi
|
|
|
|
|
|
|
|
|
|
# lcov on macOS
|
|
|
|
|
- if [ "$TRAVIS_OS_NAME" == "osx" ]; then HOMEBREW_NO_AUTO_UPDATE=1 brew install lcov; fi
|
|
|
|
|
|
|
|
|
|
script:
|
|
|
|
|
- if [ "$TARGET" == "desktop" ] && ( [ "$TRAVIS_OS_NAME" == "linux" ] || [ "$TRAVIS_OS_NAME" == "osx" ] ); then ./package/ci/travis-desktop.sh; fi
|
|
|
|
|
- if [ "$TARGET" == "desktop-gles" ] && ( [ "$TRAVIS_OS_NAME" == "linux" ] || [ "$TRAVIS_OS_NAME" == "osx" ] ); then ./package/ci/travis-desktop-gles.sh; fi
|
|
|
|
|
# Travis somehow is not able to gather all output, try to force it using this
|
|
|
|
|
- sync
|
|
|
|
|
|
|
|
|
|
after_success:
|
|
|
|
|
# Keep in sync with package/archlinux/PKGBUILD-coverage, please
|
|
|
|
|
- if [ "$TRAVIS_OS_NAME" == "linux" ] || [ "$TRAVIS_OS_NAME" == "osx" ]; then lcov $LCOV_EXTRA_OPTS --directory . --capture --output-file coverage.info > /dev/null; fi
|
|
|
|
|
- if [ "$TRAVIS_OS_NAME" == "linux" ] || [ "$TRAVIS_OS_NAME" == "osx" ]; then lcov $LCOV_EXTRA_OPTS --extract coverage.info "*/src/python/*" --output-file coverage.info; fi
|
|
|
|
|
|
|
|
|
|
- if [ "$TRAVIS_OS_NAME" == "linux" ] || [ "$TRAVIS_OS_NAME" == "osx" ]; then cd src/python && coverage combine && codecov -X gcov; fi
|