forked from OpenSCAP/openscap
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
71 lines (67 loc) · 2.01 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
language: c
matrix:
include:
- os: linux
addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- cmake
- lcov
- libdbus-1-dev
- libdbus-glib-1-dev
- libcurl4-openssl-dev
- libgcrypt-dev
- libselinux1-dev
- libgconf2-dev
- libacl1-dev
- libblkid-dev
- libcap-dev
- libxml2-dev
- swig
- libxml-parser-perl
- libxml-xpath-perl
- libperl-dev
- librpm-dev
- swig
- librtmp-dev
- xsltproc
- gcc-7
before_script:
- export CC=gcc-7 GCOV=gcov-7
- cd build
script:
- CFLAGS="--coverage -ftest-coverage -fprofile-arcs" LDFLAGS=-lgcov cmake -DCMAKE_BUILD_TYPE=Debug ../
- build-wrapper-linux-x86-64 --out-dir bw-output make all || true # Will always fail builds on forked repositories.
- make all
- CTEST_OUTPUT_ON_FAILURE=1 ctest || { test "$SEND_COVERAGE_EVEN_IF_TESTS_FAIL" = yes && curl -s https://codecov.io/bash > cov.sh && bash cov.sh -x "$GCOV"; }
- bash ../tests/recursively_generate_gcov.sh . || true # Failures that occur here are harmless
- cd .. && sonar-scanner || true # Will always fail builds on forked repositories.
after_success:
- curl -s https://codecov.io/bash > cov.sh && bash cov.sh -x "$GCOV"
- os: osx
osx_image: xcode8.3
before_install:
- brew update
- brew upgrade python
- brew install doxygen --with-graphviz
- brew install opendbx
- brew install popt
- brew install swig
before_script:
- cd build
script:
- cmake -DENABLE_PROBES=false ../
- make -j 4
addons:
sonarcloud:
organization: "openscap"
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- gcc-7
cache:
directories:
- '$HOME/.sonar/cache'