forked from rsyslog/rsyslog
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
63 lines (57 loc) · 3.9 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
language: c
compiler:
- gcc
- clang
# you can comment this in if a large number of known-good
# merges is to happen and only buildbot testing is desired
#branches:
# except:
# - master-candidate
matrix:
exclude:
- compiler: "gcc"
- compiler: "clang"
include:
- compiler: "gcc"
env: CFLAGS="-g -O2 -W -Wall -Wformat-security -Wshadow -Wcast-align -Wpointer-arith -Wmissing-format-attribute"
- compiler: "clang"
env: CFLAGS="-g -O1 -fsanitize=address -fno-color-diagnostics"
- compiler: "clang"
env: STAT_AN="YES", GROK="YES", CFLAGS="-g -O1 -std=c99"
dist: trusty
before_install:
#- travis_retry sudo apt-get install -qq python-software-properties
- travis_retry sudo add-apt-repository ppa:adiscon/v8-stable -y
- travis_retry sudo apt-get update -qq
install:
- travis_retry sudo apt-get install -qq build-essential automake pkg-config libtool autoconf autotools-dev gdb valgrind libdbi-dev libsnmp-dev libmysqlclient-dev postgresql-client
- travis_retry sudo apt-get install -qq libestr-dev librelp-dev libjson0-dev zlib1g-dev uuid-dev libgcrypt11-dev liblogging-stdlog-dev bison flex libksi1 libksi1-dev
- travis_retry sudo apt-get install -qq python-docutils liblognorm1-dev
- if [ "$CC" == "clang" ]; then travis_retry sudo apt-get install -qq clang; fi
- if [ "x$GROK" == "xYES" ]; then travis_retry sudo apt-get install -qq libglib2.0-dev libgrok1 libgrok-dev libtokyocabinet-dev ; fi
script:
- autoreconf --force --verbose --install
# I don't know how to pass two env vars in the include matrix, so
# I set the second one here via an "if"
- if [ "x$GROK" == "xYES" ]; then export GROK="--enable-mmgrok"; fi
- if [ "$CC" == "clang" ]; then export NO_VALGRIND="--without-valgrind-testbench"; fi
- ./configure --prefix=/opt/rsyslog --build=x86_64-pc-linux-gnu --host=x86_64-pc-linux-gnu --mandir=/usr/share/man --infodir=/usr/share/info --datadir=/usr/share --sysconfdir=/etc --localstatedir=/var/lib --disable-dependency-tracking --enable-silent-rules --libdir=/usr/lib64 --docdir=/usr/share/doc/rsyslog --disable-generate-man-pages --enable-testbench --enable-imdiag --enable-imfile --enable-impstats --enable-imptcp --enable-mmanon --enable-mmaudit --enable-mmfields --enable-mmjsonparse --enable-mmpstrucdata --enable-mmsequence --enable-mmutf8fix --enable-mail --enable-omprog --enable-omruleset --enable-omstdout --enable-omuxsock --enable-pmaixforwardedfrom --enable-pmciscoios --enable-pmcisconames --enable-pmlastmsg --enable-pmsnare --enable-libgcrypt --enable-mmnormalize --disable-omudpspoof --enable-imudp --enable-relp --disable-snmp --disable-mmsnmptrapd --enable-gnutls --enable-mysql --enable-gt-ksi --enable-libdbi --enable-pgsql --enable-omhttpfs $NO_VALGRIND $GROK
- export USE_AUTO_DEBUG="off" # set to "on" to enable this for travis
- make
- if [ "x$STAT_AN" == "x" ] ; then make check ; fi
- if [ "x$STAT_AN" == "x" ] ; then make distcheck ; fi
#- if [ "x$STAT_AN" == "x" ] ; then cat tests/test-suite.log; fi
- if [ "x$STAT_AN" == "xYES" ] ; then make clean ; fi
- if [ "x$STAT_AN" == "xYES" ] ; then cd compat; scan-build --status-bugs make && cd .. ; fi
# we now build those components that we know to need some more work
# they will not be included in the later static analyzer run. But by
# explicitely listing the modules which do not work, we automatically
# get new modules/files covered.
- if [ "x$STAT_AN" == "xYES" ] ; then cd runtime; make lmnet_la-net.lo libgcry_la-libgcry.lo ; cd .. ; fi
#- if [ "x$STAT_AN" == "xYES" ] ; then cd plugins/omkafka; make && cd ../..; fi
#- if [ "x$STAT_AN" == "xYES" ] ; then cd plugins/pmciscoios; make && cd ../..; fi
- if [ "x$STAT_AN" == "xYES" ] ; then scan-build --status-bugs make ; fi
# if that all worked, we go the traditional gcc & valgrind way
#- env TESTS="json_array_looping.sh" make -e check
# only for newer autoconf tools you need to add:
# - cat tests/test-suite.log