Radek Krejci | c22fd3a | 2016-01-19 14:14:32 +0100 | [diff] [blame] | 1 | language: c |
| 2 | |
Michal Vasko | 7f5c1c6 | 2016-07-21 13:42:53 +0200 | [diff] [blame] | 3 | matrix: |
| 4 | include: |
| 5 | - os: linux |
| 6 | dist: trusty |
| 7 | sudo: required |
| 8 | compiler: clang |
Juraj Vijtiuk | 80951fc | 2020-11-10 02:52:59 +0100 | [diff] [blame] | 9 | env: SANITIZE="OFF" |
| 10 | - os: linux |
| 11 | dist: trusty |
| 12 | sudo: required |
| 13 | compiler: clang |
| 14 | env: SANITIZE="ON" |
Michal Vasko | 7f5c1c6 | 2016-07-21 13:42:53 +0200 | [diff] [blame] | 15 | - os: linux |
| 16 | dist: trusty |
| 17 | sudo: required |
| 18 | compiler: gcc |
Juraj Vijtiuk | 80951fc | 2020-11-10 02:52:59 +0100 | [diff] [blame] | 19 | env: SANITIZE="OFF" |
Michal Vasko | 7f5c1c6 | 2016-07-21 13:42:53 +0200 | [diff] [blame] | 20 | - os: osx |
| 21 | compiler: gcc |
Juraj Vijtiuk | 80951fc | 2020-11-10 02:52:59 +0100 | [diff] [blame] | 22 | env: SANITIZE="OFF" |
Michal Vasko | 7f5c1c6 | 2016-07-21 13:42:53 +0200 | [diff] [blame] | 23 | allow_failures: |
| 24 | - os: osx |
Radek Krejci | c22fd3a | 2016-01-19 14:14:32 +0100 | [diff] [blame] | 25 | |
| 26 | branches: |
| 27 | only: |
| 28 | - master |
| 29 | - devel |
| 30 | |
| 31 | before_install: |
Michal Vasko | 1d70e10 | 2018-03-23 13:31:21 +0100 | [diff] [blame] | 32 | - eval "${MATRIX_EVAL}" |
Michal Vasko | 7f5c1c6 | 2016-07-21 13:42:53 +0200 | [diff] [blame] | 33 | - if [ "$TRAVIS_OS_NAME" = "linux" ]; then bash .travis-deps-linux.sh; fi |
| 34 | - if [ "$TRAVIS_OS_NAME" = "linux" -a "$CC" = "gcc" ]; then pip install --user codecov; export CFLAGS="-coverage"; fi |
| 35 | - if [ "$TRAVIS_OS_NAME" = "osx" ]; then bash .travis-deps-osx.sh; fi |
Radek Krejci | c1bf9bf | 2016-02-04 17:20:37 +0100 | [diff] [blame] | 36 | |
Michal Vasko | 50c8d3e | 2016-02-25 15:03:15 +0100 | [diff] [blame] | 37 | script: |
Claus Klein | 2209191 | 2020-01-20 13:45:47 +0100 | [diff] [blame] | 38 | - if [ "$TRAVIS_OS_NAME" = "osx" ]; then export OPENSSLFLAGS="-DOPENSSL_ROOT_DIR=/usr/local/opt/openssl"; fi |
Juraj Vijtiuk | 80951fc | 2020-11-10 02:52:59 +0100 | [diff] [blame] | 39 | - if [ "$SANITIZE" = "ON" ]; then export SANITIZEFLAGS='-DCMAKE_C_FLAGS="-fsanitize=address,undefined" -DENABLE_VALGRIND_TESTS=OFF'; fi |
| 40 | - 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 |
| 41 | - 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 |
| 42 | - 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 |
| 43 | - 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 |
| 44 | - 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 |
PavolVican | 384786e | 2017-07-12 15:31:20 +0200 | [diff] [blame] | 45 | - cd - |
Radek Krejci | c22fd3a | 2016-01-19 14:14:32 +0100 | [diff] [blame] | 46 | |
Radek Krejci | c1bf9bf | 2016-02-04 17:20:37 +0100 | [diff] [blame] | 47 | after_success: |
PavolVican | 384786e | 2017-07-12 15:31:20 +0200 | [diff] [blame] | 48 | - if [ "$TRAVIS_OS_NAME" = "linux" -a "$CC" = "gcc" ]; then codecov; ./packages/create-package.sh; fi |