forked from gammu/gammu
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
56 lines (56 loc) · 1.42 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
os:
- linux
- osx
language: cpp
compiler:
- gcc
- clang
env:
matrix:
- ARGS=""
global:
- CTEST_OUTPUT_ON_FAILURE=1
- TESTARGS="-DMYSQL_TESTING=on -DPSQL_TESTING=ON -DMYSQL_USER=root -DPSQL_USER=postgres -DPSQL_PASSWORD="
before_script:
- if [ $TRAVIS_OS_NAME = linux ] ; then psql -c 'create database smsd;' -U postgres ; fi
- if [ $TRAVIS_OS_NAME = linux ] ; then mysql -uroot -e "create database smsd;" ; fi
- if [ $TRAVIS_OS_NAME = linux ] ; then mysql -uroot -e "SET PASSWORD = PASSWORD('smsd')" ; fi
- if [ $TRAVIS_OS_NAME != linux ] ; then export TESTARGS= ; fi
- mkdir _build
- cd _build
- ln -s ../codecov.yml .
script:
- cmake .. -DCMAKE_C_COMPILER=$CC -DENABLE_COVERAGE=ON -DCMAKE_BUILD_TYPE=Continuous -DONLINE_TESTING=ON $TESTARGS $ARGS
- make || travis_terminate 1
- make test
after_success:
- make gcov
- bash <(curl -s https://codecov.io/bash) -X gcov -F $TRAVIS_OS_NAME
# install build dependencies and enable Coverity scan
addons:
apt:
packages:
- libbluetooth-dev
- libusb-1.0-0-dev
- libgudev-1.0-dev
- unixodbc-dev
- libdbi-dev
- libdbd-sqlite3
- libdbd-mysql
- libdbd-pgsql
- cmake
- cmake-data
matrix:
exclude:
- os: osx
compiler: gcc
include:
- os: linux
compiler: gcc
env: ARGS="-DENABLE_GETOPT=OFF"
- os: linux
compiler: gcc
env: ARGS="-DUSE_WCHAR_T=OFF"
services:
- mysql
- postgresql