-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy path.travis.yml
76 lines (68 loc) · 2.55 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
72
73
74
75
76
language: c
sudo: required
dist: trusty
env:
global:
- secure: "nAc3WvwtJBm+hLIYxp4srwgM7qDWRovkEpsza+UITEE8TUqeZND2543xMZlWz1w5qn8V/F/1yX1oYl7Ot0ymmu9Uh41b1NBr3cvo2U8RLDSM9SBoqtyS1pSCnJ2qiSk+hg5GxObWug/ph3TkEgZaDmYCDAgHiv1I9WXVRxeR144="
- COVERITY_SCAN_BRANCH_PATTERN="(master|coverity-.*)"
- COVERITY_SCAN_NOTIFICATION_EMAIL="[email protected]"
- COVERITY_SCAN_BUILD_COMMAND="make"
- COVERITY_SCAN_PROJECT_NAME="$TRAVIS_REPO_SLUG"
- LIBSNDFILE_URL="http://www.mega-nerd.com/libsndfile/files/libsndfile-1.0.27.tar.gz"
- LD_LIBRARY_PATH=/usr/local/lib
os:
- linux
- osx
compiler:
- clang
- gcc
addons:
apt:
packages:
- libvorbis-dev
- libflac-dev
- libasound2-dev
- doxygen
- lcov
- ca-certificates
matrix:
include:
- compiler: gcc
env:
- DO_EXTRA="coverage"
- CFLAGS="-g -O0 --coverage"
- CXXFLAGS="-g -O0 --coverage"
- LDFLAGS="--coverage"
- CONFIGUREFLAGS="--enable-debug"
- compiler: gcc
env:
- DO_EXTRA="coverity"
exclude:
- os: osx
compiler: gcc
install:
## build libsndfile
- mkdir -p libsndfile/build && curl "$LIBSNDFILE_URL" | tar --strip-components=1 -C libsndfile -xvzf -
- cd libsndfile/build && ../configure --disable-silent-rules && make && sudo make install
## remove coverage traces
- find . -name "*.gcda" -delete
- find . -name "*.gcno" -delete
## remove libtool libs
- find /usr/local/lib -type f -name "*.la" -exec sudo rm -f {} \+
before_script:
# configure the build
- cd "$TRAVIS_BUILD_DIR"
- ./autogen.sh
- ./configure --disable-silent-rules ${CONFIGUREFLAGS}
# OMG, Coverity scan uses a certificate not supported by travis-ci
- if [ -d /etc/ssl/certs/ ] ; then echo -n | openssl s_client -connect scan.coverity.com:443 | sed -ne '/-BEGIN CERTIFICATE-/,/-END CERTIFICATE-/p' | sudo tee -a /etc/ssl/certs/ca-certificates.crt; fi
# implement Coverity Scan with before_script instead of addons.coverity_scan
# to work around too-early quota check by the coverity_scan addon
- if [[ "x${DO_EXTRA}" = "xcoverity" ]] ; then curl -s 'https://scan.coverity.com/scripts/travisci_build_coverity_scan.sh' | bash || true ; fi
script:
- make
- if [[ "x${DO_EXTRA}" = "x" ]] ; then make distcheck; fi
after_success:
- if [[ "x${DO_EXTRA}" = "xcoverage" ]] ; then LD_LIBRARY_PATH=/usr/local/lib ./coverage.sh; fi
- if [[ "yes.${TRAVIS_BRANCH}.${TRAVIS_PULLREQUEST}" = "yes.master." ]]; then ./.deploy-documentation.sh ; fi
- bash <(curl -s https://codecov.io/bash)