Radek Krejci | 1ba11c4 | 2015-06-15 13:40:36 +0200 | [diff] [blame] | 1 | language: c |
Radek Krejci | 6757fae | 2015-06-15 14:42:01 +0200 | [diff] [blame] | 2 | |
Radek Krejci | a028759 | 2016-07-19 14:04:07 +0200 | [diff] [blame] | 3 | matrix: |
| 4 | include: |
Michal Vasko | e899549 | 2019-10-18 09:14:42 +0200 | [diff] [blame] | 5 | - arch: amd64 |
Michal Vasko | 9b2b162 | 2019-10-18 09:12:11 +0200 | [diff] [blame] | 6 | os: linux |
Michal Vasko | 849287a | 2019-10-18 10:13:37 +0200 | [diff] [blame] | 7 | dist: bionic |
Radek Krejci | a028759 | 2016-07-19 14:04:07 +0200 | [diff] [blame] | 8 | sudo: required |
| 9 | compiler: clang |
Michal Vasko | 4e8d59c | 2019-10-18 09:36:38 +0200 | [diff] [blame] | 10 | env: TRAVIS_ARCH="amd64" |
Michal Vasko | e899549 | 2019-10-18 09:14:42 +0200 | [diff] [blame] | 11 | - arch: amd64 |
Michal Vasko | 9b2b162 | 2019-10-18 09:12:11 +0200 | [diff] [blame] | 12 | os: linux |
Michal Vasko | 849287a | 2019-10-18 10:13:37 +0200 | [diff] [blame] | 13 | dist: bionic |
Radek Krejci | a028759 | 2016-07-19 14:04:07 +0200 | [diff] [blame] | 14 | sudo: required |
| 15 | compiler: gcc |
Michal Vasko | 4e8d59c | 2019-10-18 09:36:38 +0200 | [diff] [blame] | 16 | env: TRAVIS_ARCH="amd64" |
Michal Vasko | e899549 | 2019-10-18 09:14:42 +0200 | [diff] [blame] | 17 | - arch: arm64 |
| 18 | os: linux |
Michal Vasko | 849287a | 2019-10-18 10:13:37 +0200 | [diff] [blame] | 19 | dist: bionic |
Michal Vasko | e899549 | 2019-10-18 09:14:42 +0200 | [diff] [blame] | 20 | sudo: required |
| 21 | compiler: gcc |
Michal Vasko | 4e8d59c | 2019-10-18 09:36:38 +0200 | [diff] [blame] | 22 | env: TRAVIS_ARCH="arm64" |
Michal Vasko | e899549 | 2019-10-18 09:14:42 +0200 | [diff] [blame] | 23 | - arch: amd64 |
Michal Vasko | 9b2b162 | 2019-10-18 09:12:11 +0200 | [diff] [blame] | 24 | os: linux |
Michal Vasko | 849287a | 2019-10-18 10:13:37 +0200 | [diff] [blame] | 25 | dist: bionic |
Michal Vasko | 731f9c6 | 2019-04-16 16:23:07 +0200 | [diff] [blame] | 26 | sudo: required |
| 27 | compiler: gcc |
Michal Vasko | 4e8d59c | 2019-10-18 09:36:38 +0200 | [diff] [blame] | 28 | env: TRAVIS_ARCH="amd64" ENABLE_STATIC=ON |
Michal Vasko | 9b2b162 | 2019-10-18 09:12:11 +0200 | [diff] [blame] | 29 | - arch: amd64 |
| 30 | os: osx |
Radek Krejci | a028759 | 2016-07-19 14:04:07 +0200 | [diff] [blame] | 31 | compiler: gcc |
Michal Vasko | 4e8d59c | 2019-10-18 09:36:38 +0200 | [diff] [blame] | 32 | env: TRAVIS_ARCH="amd64" |
Radek Krejci | a028759 | 2016-07-19 14:04:07 +0200 | [diff] [blame] | 33 | allow_failures: |
| 34 | - os: osx |
Radek Krejci | 6757fae | 2015-06-15 14:42:01 +0200 | [diff] [blame] | 35 | |
Radek Krejci | 1ba11c4 | 2015-06-15 13:40:36 +0200 | [diff] [blame] | 36 | branches: |
| 37 | only: |
| 38 | - master |
Radek Krejci | 2bb207f | 2015-08-13 08:11:10 +0200 | [diff] [blame] | 39 | - devel |
Radek Krejci | 1ba11c4 | 2015-06-15 13:40:36 +0200 | [diff] [blame] | 40 | |
Radek Krejci | 5936e19 | 2015-10-05 15:56:31 +0200 | [diff] [blame] | 41 | before_install: |
Lukas Macko | 5f490e6 | 2016-10-31 11:08:39 +0100 | [diff] [blame] | 42 | - git clone git://git.cryptomilk.org/projects/cmocka.git |
| 43 | - cd cmocka && mkdir build && cd build |
Radek Krejci | 51aa74c | 2018-02-01 08:56:25 +0100 | [diff] [blame] | 44 | - cmake .. && make -j2 && sudo make install |
Radek Krejci | 1f8d223 | 2015-10-05 16:34:12 +0200 | [diff] [blame] | 45 | - cd ../.. |
Michal Vasko | b469b6d | 2018-02-15 15:53:44 +0100 | [diff] [blame] | 46 | - if [ "$TRAVIS_OS_NAME" = "osx" ]; then brew update; fi |
Michal Vasko | 65644a3 | 2019-10-18 10:22:26 +0200 | [diff] [blame] | 47 | - if [ "$TRAVIS_OS_NAME" = "linux" ]; then sudo apt-get update -qq; sudo apt-get install -y valgrind libpcre3-dev python3-dev swig; fi |
Michal Vasko | 29aaab8 | 2019-10-18 10:28:00 +0200 | [diff] [blame] | 48 | - if [ "$TRAVIS_OS_NAME" = "linux" -a "$CC" = "gcc" -a "$TRAVIS_ARCH" = "amd64" ]; then pip install --user codecov; export CFLAGS="-coverage"; fi |
Radek Krejci | 5936e19 | 2015-10-05 15:56:31 +0200 | [diff] [blame] | 49 | |
Michal Vasko | fe4b7c7 | 2016-05-18 13:44:21 +0200 | [diff] [blame] | 50 | script: |
Michal Vasko | 57e70c9 | 2018-02-15 15:56:01 +0100 | [diff] [blame] | 51 | - mkdir build && cd build |
Radek Krejci | 0e6388e | 2018-12-11 09:22:16 +0100 | [diff] [blame] | 52 | - if [ "$TRAVIS_OS_NAME" = "osx" ]; then cmake -DENABLE_VALGRIND_TESTS=OFF ..; fi |
Michal Vasko | 4624138 | 2019-10-18 10:19:49 +0200 | [diff] [blame] | 53 | - if [ "$TRAVIS_OS_NAME" = "linux" -a "$TRAVIS_ARCH" = "amd64" ]; then cmake -DGEN_LANGUAGE_BINDINGS=ON -DENABLE_STATIC=${ENABLE_STATIC:-OFF} ..; fi |
| 54 | - if [ "$TRAVIS_OS_NAME" = "linux" -a "$TRAVIS_ARCH" = "arm64" ]; then cmake -DGEN_LANGUAGE_BINDINGS=ON -DENABLE_VALGRIND_TESTS=OFF ..; fi |
Michal Vasko | 57e70c9 | 2018-02-15 15:56:01 +0100 | [diff] [blame] | 55 | - make -j2 && ctest --output-on-failure |
Radek Krejci | 9d42d0a | 2017-04-28 13:33:33 +0200 | [diff] [blame] | 56 | - cd - |
Radek Krejci | 6757fae | 2015-06-15 14:42:01 +0200 | [diff] [blame] | 57 | |
Radek Krejci | 1a7c6e0 | 2016-02-04 16:10:52 +0100 | [diff] [blame] | 58 | after_success: |
Michal Vasko | 29aaab8 | 2019-10-18 10:28:00 +0200 | [diff] [blame] | 59 | - if [ "$TRAVIS_OS_NAME" = "linux" -a "$CC" = "gcc" -a "$TRAVIS_ARCH" = "amd64" ]; then codecov; ./packages/create-package.sh; fi |