blob: 92e96ab34cf6ba484bd9a71eb7d10aba7f7facef [file] [log] [blame]
Radek Krejci1ba11c42015-06-15 13:40:36 +02001language: c
Radek Krejci6757fae2015-06-15 14:42:01 +02002
Radek Krejcia0287592016-07-19 14:04:07 +02003matrix:
4 include:
5 - os: linux
6 dist: trusty
7 sudo: required
8 compiler: clang
9 - os: linux
10 dist: trusty
11 sudo: required
12 compiler: gcc
13 - os: osx
14 compiler: gcc
15 allow_failures:
16 - os: osx
Radek Krejci6757fae2015-06-15 14:42:01 +020017
Radek Krejci1ba11c42015-06-15 13:40:36 +020018branches:
19 only:
20 - master
Radek Krejci2bb207f2015-08-13 08:11:10 +020021 - devel
Radek Krejci1ba11c42015-06-15 13:40:36 +020022
Radek Krejci5936e192015-10-05 15:56:31 +020023before_install:
Radek Krejcib1eb0012015-10-05 16:29:13 +020024 - wget https://cmocka.org/files/1.0/cmocka-1.0.1.tar.xz
25 - tar -xJvf cmocka-1.0.1.tar.xz
26 - cd cmocka-1.0.1 && mkdir build && cd build
Radek Krejciafb92262016-01-19 10:04:48 +010027 - cmake -DCMAKE_INSTALL_PREFIX:PATH=/usr .. && make -j2 && sudo make install
Radek Krejci1f8d2232015-10-05 16:34:12 +020028 - cd ../..
Radek Krejcif4e5fd22016-07-19 14:21:13 +020029 - if [ "$TRAVIS_OS_NAME" = "osx" ]; then brew update; brew install pcre; brew install valgrind; fi
30 - if [ "$TRAVIS_OS_NAME" = "linux" ]; then sudo apt-get update -qq; sudo apt-get install -y valgrind; fi
Radek Krejcia0287592016-07-19 14:04:07 +020031 - if [ "$TRAVIS_OS_NAME" = "linux" -a "$CC" = "gcc" ]; then pip install --user codecov; export CFLAGS="-coverage"; fi
Radek Krejci5936e192015-10-05 15:56:31 +020032
Michal Vaskofe4b7c72016-05-18 13:44:21 +020033script:
Radek Krejci978ff502016-07-19 14:25:22 +020034 - mkdir build && cd build && cmake .. && make -j2 && ctest --output-on-failure
Radek Krejci6757fae2015-06-15 14:42:01 +020035
Radek Krejci1a7c6e02016-02-04 16:10:52 +010036after_success:
Radek Krejcia0287592016-07-19 14:04:07 +020037 - if [ "$TRAVIS_OS_NAME" = "linux" -a "$CC" = "gcc" ]; then codecov; fi
Radek Krejci1a7c6e02016-02-04 16:10:52 +010038