| language: c |
| |
| matrix: |
| include: |
| - os: linux |
| dist: trusty |
| sudo: required |
| compiler: clang |
| env: SANITIZE="OFF" |
| - os: linux |
| dist: trusty |
| sudo: required |
| compiler: clang |
| env: SANITIZE="ON" |
| - os: linux |
| dist: trusty |
| sudo: required |
| compiler: gcc |
| env: SANITIZE="OFF" |
| - os: osx |
| compiler: gcc |
| env: SANITIZE="OFF" |
| allow_failures: |
| - os: osx |
| |
| branches: |
| only: |
| - master |
| - devel |
| |
| before_install: |
| - eval "${MATRIX_EVAL}" |
| - if [ "$TRAVIS_OS_NAME" = "linux" ]; then bash .travis-deps-linux.sh; fi |
| - if [ "$TRAVIS_OS_NAME" = "linux" -a "$CC" = "gcc" ]; then pip install --user codecov; export CFLAGS="-coverage"; fi |
| - if [ "$TRAVIS_OS_NAME" = "osx" ]; then bash .travis-deps-osx.sh; fi |
| |
| script: |
| - if [ "$TRAVIS_OS_NAME" = "osx" ]; then export OPENSSLFLAGS="-DOPENSSL_ROOT_DIR=/usr/local/opt/openssl"; fi |
| - if [ "$SANITIZE" = "ON" ]; then export SANITIZEFLAGS='-DCMAKE_C_FLAGS="-fsanitize=address,undefined" -DENABLE_VALGRIND_TESTS=OFF'; fi |
| - cd $TRAVIS_BUILD_DIR && mkdir build_none && cd build_none ; cmake -DENABLE_TLS=OFF -DENABLE_SSH=OFF -DENABLE_DNSSEC=OFF $SANITIZEFLAGS .. && make -j2 && ctest --output-on-failure |
| - cd $TRAVIS_BUILD_DIR && mkdir build_tls && cd build_tls ; cmake $OPENSSLFLAGS -DENABLE_TLS=ON -DENABLE_SSH=OFF -DENABLE_DNSSEC=OFF $SANITIZEFLAGS .. && make -j2 && ctest --output-on-failure |
| - cd $TRAVIS_BUILD_DIR && mkdir build_ssh && cd build_ssh ; cmake $OPENSSLFLAGS -DENABLE_TLS=OFF -DENABLE_SSH=ON -DENABLE_DNSSEC=OFF $SANITIZEFLAGS .. && make -j2 && ctest --output-on-failure |
| - cd $TRAVIS_BUILD_DIR && mkdir build_ssh_tls && cd build_ssh_tls ; cmake $OPENSSLFLAGS -DENABLE_TLS=ON -DENABLE_SSH=ON -DENABLE_DNSSEC=OFF $SANITIZEFLAGS .. && make -j2 && ctest --output-on-failure |
| - cd $TRAVIS_BUILD_DIR && mkdir build_all && cd build_all ; cmake $OPENSSLFLAGS -DENABLE_TLS=ON -DENABLE_SSH=ON -DENABLE_DNSSEC=ON $SANITIZEFLAGS .. && make -j2 && ctest --output-on-failure |
| - cd - |
| |
| after_success: |
| - if [ "$TRAVIS_OS_NAME" = "linux" -a "$CC" = "gcc" ]; then codecov; ./packages/create-package.sh; fi |