Make sure we treat records written after HRR as TLSv1.3
[oweals/openssl.git] / .travis.yml
1 dist: trusty
2 sudo: required
3
4 language: c
5 cache: ccache
6 git:
7     submodules: false
8
9 before_install:
10     - if [ -n "$COVERALLS" ]; then
11           pip install --user cpp-coveralls;
12       fi;
13     - if expr "$CONFIG_OPTS" ":" ".*enable-external-tests" > /dev/null; then
14           git submodule update --init --recursive;
15       fi;
16
17 addons:
18     apt:
19         packages:
20             - ccache
21             - golang-1.6
22
23 os:
24     - linux
25
26 compiler:
27     - clang
28     - gcc
29
30 env:
31     - CONFIG_OPTS="" DESTDIR="_install" TESTS="-test_fuzz"
32     - CONFIG_OPTS="no-asm -Werror --debug no-afalgeng no-shared enable-crypto-mdebug enable-rc5 enable-md2 enable-aria" TESTS="-test_fuzz"
33     - CONFIG_OPTS="no-asm --strict-warnings" BUILDONLY="yes" CHECKDOCS="yes"
34
35 matrix:
36     include:
37         - os: linux
38           addons:
39               apt:
40                   packages:
41                       - gcc-5
42                       - g++-5
43                   sources:
44                       - ubuntu-toolchain-r-test
45           compiler: gcc-5
46           env: CONFIG_OPTS="--strict-warnings enable-tls1_3" TESTS="-test_fuzz" COMMENT="Move to the BORINGTEST build when interoperable"
47         - os: linux
48           compiler: clang-3.9
49           env: CONFIG_OPTS="--strict-warnings no-deprecated" BUILDONLY="yes"
50         - os: linux
51           addons:
52               apt:
53                   packages:
54                       - binutils-mingw-w64
55                       - gcc-mingw-w64
56           compiler: i686-w64-mingw32-gcc
57           env: CONFIG_OPTS="no-stdio" BUILDONLY="yes"
58         - os: linux
59           addons:
60               apt:
61                   packages:
62                       - gcc-5
63                       - g++-5
64                   sources:
65                       - ubuntu-toolchain-r-test
66           compiler: gcc-5
67           env:  EXTENDED_TEST="yes" CONFIG_OPTS="--debug --coverage no-asm enable-rc5 enable-md2 enable-aria enable-ec_nistp_64_gcc_128 enable-ssl3 enable-ssl3-method enable-nextprotoneg enable-weak-ssl-ciphers no-shared -DPEDANTIC -DFUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION" COVERALLS="yes" BORINGSSL_TESTS="yes" CXX="g++-5"
68         - os: linux
69           addons:
70               apt:
71                   packages:
72                       - gcc-5
73                       - g++-5
74                   sources:
75                       - ubuntu-toolchain-r-test
76           compiler: gcc-5
77           env:  EXTENDED_TEST="yes" CONFIG_OPTS="--debug enable-ssl3 enable-ssl3-method enable-weak-ssl-ciphers enable-external-tests" BORINGSSL_TESTS="yes" CXX="g++-5" TESTS=95
78         - os: linux
79           compiler: clang-3.9
80           env: EXTENDED_TEST="yes" CONFIG_OPTS="enable-msan"
81         - os: linux
82           compiler: clang-3.9
83           env:  EXTENDED_TEST="yes" CONFIG_OPTS="no-asm enable-ubsan enable-rc5 enable-md2 enable-aria enable-ssl3 enable-ssl3-method enable-nextprotoneg -fno-sanitize=alignment no-shared -DFUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION"
84         - os: linux
85           compiler: clang-3.9
86           env: EXTENDED_TEST="yes" CONFIG_OPTS="no-asm enable-asan enable-rc5 enable-md2 enable-aria no-shared -DFUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION"
87         - os: linux
88           addons:
89               apt:
90                   packages:
91                       - gcc-5
92                       - g++-5
93                   sources:
94                       - ubuntu-toolchain-r-test
95           compiler: gcc-5
96           env: EXTENDED_TEST="yes" CONFIG_OPTS="--debug no-asm enable-ubsan enable-rc5 enable-md2 enable-aria -DPEDANTIC" OPENSSL_TEST_RAND_ORDER=0
97         - os: linux
98           addons:
99               apt:
100                   packages:
101                       - binutils-mingw-w64
102                       - gcc-mingw-w64
103           compiler: i686-w64-mingw32-gcc
104           env: EXTENDED_TEST="yes" CONFIG_OPTS="no-pic" TESTS="-test_fuzz"
105         - os: linux
106           addons:
107               apt:
108                   packages:
109                       - binutils-mingw-w64
110                       - gcc-mingw-w64
111           compiler: x86_64-w64-mingw32-gcc
112           env: EXTENDED_TEST="yes" CONFIG_OPTS="no-pic" TESTS="-test_fuzz"
113     exclude:
114         - os: linux
115           compiler: clang
116         - os: osx
117           compiler: gcc
118
119 before_script:
120     - env
121     - if [ "$TRAVIS_PULL_REQUEST" != "false" -a -n "$EXTENDED_TEST" ]; then
122           (git log -1 $TRAVIS_COMMIT_RANGE | grep '\[extended tests\]' > /dev/null) || exit 0;
123       fi
124     - if [ -n "$DESTDIR" ]; then
125           sh .travis-create-release.sh $TRAVIS_OS_NAME;
126           tar -xvzf _srcdist.tar.gz;
127           mkdir _build;
128           cd _build;
129           srcdir=../_srcdist;
130           top=..;
131       else
132           srcdir=.;
133           top=.;
134       fi
135     - if [ "$CC" == i686-w64-mingw32-gcc ]; then
136           export CROSS_COMPILE=${CC%%gcc}; unset CC;
137           $srcdir/Configure mingw $CONFIG_OPTS -Wno-pedantic-ms-format;
138       elif [ "$CC" == x86_64-w64-mingw32-gcc ]; then
139           export CROSS_COMPILE=${CC%%gcc}; unset CC;
140           $srcdir/Configure mingw64 $CONFIG_OPTS -Wno-pedantic-ms-format;
141       else
142           if [ "$CC" == clang-3.9 ]; then
143               sudo cp .travis-apt-pin.preferences /etc/apt/preferences.d/no-ubuntu-clang;
144               curl -sSL "http://apt.llvm.org/llvm-snapshot.gpg.key" | sudo -E apt-key add -;
145               echo "deb http://apt.llvm.org/trusty/ llvm-toolchain-trusty-3.9 main" | sudo tee -a /etc/apt/sources.list > /dev/null;
146               sudo -E apt-add-repository -y "ppa:ubuntu-toolchain-r/test";
147               sudo -E apt-get -yq update;
148               sudo -E apt-get -yq --no-install-suggests --no-install-recommends --force-yes install clang-3.9;
149           elif which ccache >/dev/null; then
150               CC="ccache $CC";
151           fi;
152           $srcdir/config -v $CONFIG_OPTS;
153       fi
154     - cd $top
155
156 script:
157     - if [ -z "$BUILDONLY" ]; then
158           make="make -s";
159       else
160           make="make";
161       fi
162     - top=${PWD}
163     - if [ -n "$DESTDIR" ]; then
164           cd _build;
165       fi
166     - if $make update; then
167           echo -e '+\057 MAKE UPDATE OK';
168       else
169           echo -e '+\057 MAKE UPDATE FAILED'; false;
170       fi;
171       git diff --exit-code
172     - if [ -n "$CHECKDOCS" ]; then
173           if $make doc-nits; then
174               echo -e '+\057\057 MAKE DOC-NITS OK';
175           else
176               echo -e '+\057\057 MAKE DOC-NITS FAILED'; false;
177           fi;
178       fi
179     - if $make; then
180           echo -e '+\057\057\057 MAKE OK';
181       else
182           echo -e '+\057\057\057 MAKE FAILED'; false;
183       fi;
184     - if [ -z "$BUILDONLY" ]; then
185           if [ -n "$CROSS_COMPILE" ]; then
186               sudo dpkg --add-architecture i386;
187               sudo apt-get update;
188               sudo apt-get -yq --no-install-suggests --no-install-recommends --force-yes install wine;
189               export EXE_SHELL="wine" WINEPREFIX=`pwd`;
190           fi;
191           if [ -e krb5/src ]; then
192               sudo apt-get -yq install bison dejagnu gettext keyutils ldap-utils libldap2-dev libkeyutils-dev python-cjson python-paste python-pyrad slapd tcl-dev tcsh;
193           fi;
194           if HARNESS_VERBOSE=yes BORING_RUNNER_DIR=$top/boringssl/ssl/test/runner make test; then
195               echo -e '+\057\057\057\057 MAKE TEST OK';
196           else
197               echo -e '+\057\057\057\057 MAKE TEST FAILED'; false;
198           fi;
199       else
200           if $make build_tests; then
201               echo -e '+\057\057\057\057\057 MAKE BUILD_TESTS OK';
202           else
203               echo -e '+\057\057\057\057\057 MAKE BUILD_TESTS FAILED'; false;
204           fi;
205       fi
206     - if [ -n "$DESTDIR" ]; then
207           mkdir "$top/$DESTDIR";
208           if $make install install_docs DESTDIR="$top/$DESTDIR"; then
209               echo -e '+\057\057\057\057\057\057 MAKE INSTALL OK';
210           else
211               echo -e '+\057\057\057\057\057\057 MAKE INSTALL FAILED'; false;
212           fi;
213       fi
214     - cd $top
215
216 after_success:
217     - if [ -n "$COVERALLS" ]; then
218           coveralls -b . --gcov gcov-5 --gcov-options '\-lpbc';
219       fi;
220
221 notifications:
222     email:
223         secure: "xeGNgWO7aoaDgRvcZubposqMsj36aU8c6F0oHfw+rUqltCQ14IgYCUwzocmR2O+Pa7B3Cx5VjMfBFHbQaajZsfod8vu7g+aGq/zkjwbhsr/SR4dljJjFJXLGZjIalm9KgP6KInmVDuINfCqP+MHIY5lZkNI7DMcyHDhVc5nSKvCXV7xTDNgmstvh8rB/z51WfHDqGqfBtiuK5FDNxmvYK8OFJ5W94Lu9LDlizcxwK3GAj7arOui7Z5w8bQ6p4seUE3IvJL1Zbj0pZHxvNb6Zeb2Pn8QF1qLlN8YmBktD4aiw0ce4wYRiL87uLgcOxZY7SVXtv2XYFIYWapU/FKjCqa6vK93V/H9eZWEIYNMKnN3wXm2beqVdnKek3OeGJ8v0y7MbSfuLfRtBqbTSNYnpU1Zuo4MQAvHvEPuwCAYkYQajOSRplMH5sULFKptuVqNtOMfjL8jHb8AEoL1acYIk43ydxeYrzzas4fqgCDJ52573/u0RNdF1lkQBLkuM365OB8VRqtpnoxcdEIY/qBc/8TzZ24fxyrs5qdHFcxGSgpN2EP6cJMqpvkemnCNSdhxUqfzm22N7a3O8+4LFSBGOnHto/PwdsvF/01yGYL0LoZTnoO1i6x7AMJPBh+eyDU0ZjGhj/msjmqeb9C8vRqQ+1WjHrIS1iqCD0Czib8tUPD4="