GH429: Add clang to travis
[openssl.git] / .travis.yml
1 language: c
2
3 addons:
4     apt:
5         packages:
6             - gcc-5
7             - binutils-mingw-w64
8             - gcc-mingw-w64
9         sources:
10             - ubuntu-toolchain-r-test
11
12 os:
13     - linux
14     - osx
15
16 compiler:
17     - clang
18     - gcc
19     - gcc-5
20     - i686-w64-mingw32-gcc
21     - x86_64-w64-mingw32-gcc
22
23 env:
24     - CONFIG_OPTS=""
25     - CONFIG_OPTS="shared"
26     - CONFIG_OPTS="--debug --strict-warnings"
27
28 matrix:
29     include:
30         - os: linux
31           compiler: gcc-5
32           env: CONFIG_OPTS="--debug --strict-warnings -fsanitize=address"
33     exclude:
34         - os: osx
35           compiler: gcc-5
36         - os: osx
37           compiler: i686-w64-mingw32-gcc
38         - os: osx
39           compiler: x86_64-w64-mingw32-gcc
40     allow_failures:
41         - compiler: i686-w64-mingw32-gcc
42           env: CONFIG_OPTS="--debug --strict-warnings"
43         - compiler: x86_64-w64-mingw32-gcc
44           env: CONFIG_OPTS="--debug --strict-warnings"
45
46 before_script:
47     - if [ "$CC" == i686-w64-mingw32-gcc ]; then
48           export CROSS_COMPILE=${CC%%gcc}; unset CC;
49           ./Configure mingw $CONFIG_OPTS -Wno-pedantic-ms-format;
50       elif [ "$CC" == x86_64-w64-mingw32-gcc ]; then
51           export CROSS_COMPILE=${CC%%gcc}; unset CC;
52           ./Configure mingw64 $CONFIG_OPTS -Wno-pedantic-ms-format;
53       else
54           ./config $CONFIG_OPTS;
55       fi
56
57 script:
58     - make
59     - if [ -z "$CROSS_COMPILE" ]; then make test; fi
60
61 notifications:
62     email:
63         - openssl-commits@openssl.org