blob: fd1c0e4ee1f50ea67aa331263b51ba562130b918 [file] [log] [blame]
Davide Pesavento97242f72020-02-29 14:28:15 -05001version: ~> 1.0
Davide Pesavento9412d122018-01-02 21:52:09 -05002language: cpp
Davide Pesavento97242f72020-02-29 14:28:15 -05003os: linux
Davide Pesaventocb672522019-09-23 17:40:14 -04004dist: bionic
Davide Pesavento97242f72020-02-29 14:28:15 -05005
6arch:
7 - amd64
8 - arm64
9 - ppc64le
10 - s390x
11
Davide Pesavento09348882016-09-17 02:39:44 +020012env:
Davide Pesavento53533942020-03-04 23:10:06 -050013 - COMPILER=g++-7
14 - COMPILER=g++-9
15 - COMPILER=clang++-6.0
16 - COMPILER=clang++-9
Davide Pesavento71430482017-06-08 20:06:40 -040017
Davide Pesavento97242f72020-02-29 14:28:15 -050018jobs:
Alexander Afanasyevce306ca2015-12-09 12:59:05 -080019 include:
Davide Pesavento97242f72020-02-29 14:28:15 -050020 # Linux
Davide Pesavento71c622b2020-04-24 01:39:01 -040021 - env: COMPILER=g++-5
22 - env: COMPILER=g++-6
Davide Pesavento97242f72020-02-29 14:28:15 -050023 - env: COMPILER=g++-8
Davide Pesavento71c622b2020-04-24 01:39:01 -040024 - env: COMPILER=clang++-4.0
Davide Pesavento97242f72020-02-29 14:28:15 -050025 - env: COMPILER=clang++-5.0
26 - env: COMPILER=clang++-7
27 - env: COMPILER=clang++-8
28 - env: COMPILER=clang++-10
29 - env: COMPILER=clang++-11
Davide Pesavento599623c2020-08-07 13:05:04 -040030 - env: COMPILER=clang++-12
Davide Pesavento71430482017-06-08 20:06:40 -040031
Davide Pesavento97242f72020-02-29 14:28:15 -050032 # macOS
Davide Pesaventoca660f12018-06-16 14:01:51 -040033 - os: osx
34 osx_image: xcode9.4
Davide Pesavento97242f72020-02-29 14:28:15 -050035 env: # default compiler
Davide Pesaventod89f0022018-04-28 14:48:25 -040036 - os: osx
Davide Pesavento511712d2018-11-03 18:51:10 -040037 osx_image: xcode10.1
Davide Pesavento97242f72020-02-29 14:28:15 -050038 env: # default compiler
Davide Pesavento4fc90802019-02-21 15:20:44 -050039 - os: osx
Davide Pesaventocb672522019-09-23 17:40:14 -040040 osx_image: xcode10.3
Davide Pesavento97242f72020-02-29 14:28:15 -050041 env: # default compiler
Davide Pesavento4fc90802019-02-21 15:20:44 -050042 - os: osx
Davide Pesavento97242f72020-02-29 14:28:15 -050043 osx_image: xcode11.3
44 env: # default compiler
Davide Pesavento71c622b2020-04-24 01:39:01 -040045 - os: osx
Davide Pesaventof2c4c532020-07-01 02:44:33 -040046 osx_image: xcode11.6
47 env: # default compiler
48 - os: osx
49 osx_image: xcode12
50 env: # default compiler
Davide Pesavento9412d122018-01-02 21:52:09 -050051
52 allow_failures:
Davide Pesavento71c622b2020-04-24 01:39:01 -040053 - env: COMPILER=g++-5
54 - env: COMPILER=g++-6
55 - env: COMPILER=clang++-4.0
Davide Pesavento599623c2020-08-07 13:05:04 -040056 - env: COMPILER=clang++-12
Davide Pesavento9412d122018-01-02 21:52:09 -050057
58 fast_finish: true
Davide Pesavento71430482017-06-08 20:06:40 -040059
Davide Pesavento97242f72020-02-29 14:28:15 -050060before_install:
61 - |
62 : Adding apt repositories
Davide Pesavento844b0932018-05-07 01:00:16 -040063 case ${COMPILER} in
Davide Pesavento97242f72020-02-29 14:28:15 -050064 g++-9)
65 # https://launchpad.net/~ubuntu-toolchain-r/+archive/ubuntu/test/+packages
Davide Pesavento844b0932018-05-07 01:00:16 -040066 travis_retry sudo add-apt-repository -y ppa:ubuntu-toolchain-r/test
67 travis_retry sudo apt-get -qq update
Davide Pesavento844b0932018-05-07 01:00:16 -040068 ;;
Davide Pesavento97242f72020-02-29 14:28:15 -050069 clang++-1?)
70 # https://apt.llvm.org/
Davide Pesaventocb672522019-09-23 17:40:14 -040071 LLVM_REPO=${COMPILER/clang++/llvm-toolchain-${TRAVIS_DIST}}
72 travis_retry wget -nv -O - "https://apt.llvm.org/llvm-snapshot.gpg.key" | sudo apt-key add -
Davide Pesavento599623c2020-08-07 13:05:04 -040073 travis_retry sudo add-apt-repository -y "deb http://apt.llvm.org/${TRAVIS_DIST}/ ${LLVM_REPO%-12} main"
Davide Pesavento844b0932018-05-07 01:00:16 -040074 travis_retry sudo apt-get -qq update
Davide Pesavento844b0932018-05-07 01:00:16 -040075 ;;
76 esac
77
Davide Pesaventocb672522019-09-23 17:40:14 -040078install:
Davide Pesavento97242f72020-02-29 14:28:15 -050079 - |
80 : Installing C++ compiler
81 if [[ -n ${COMPILER} ]]; then
82 travis_retry sudo apt-get -qy install ${COMPILER/clang++/clang}
83 fi
Davide Pesaventocb672522019-09-23 17:40:14 -040084
Davide Pesavento71430482017-06-08 20:06:40 -040085before_script:
Davide Pesavento97242f72020-02-29 14:28:15 -050086 - |
87 : Setting environment variables
Davide Pesavento53533942020-03-04 23:10:06 -050088 if [[ -n ${COMPILER} ]]; then
89 export CXX=${COMPILER}
90 fi
Davide Pesavento97242f72020-02-29 14:28:15 -050091 case ${TRAVIS_OS_NAME} in
92 linux) export NODE_LABELS="Linux Ubuntu Ubuntu-18.04" ;;
93 osx) export NODE_LABELS="OSX OSX-$(sw_vers -productVersion | cut -d . -f -2)" ;;
94 esac
Davide Pesavento53533942020-03-04 23:10:06 -050095 export JOB_NAME=limited-build
96 export WAF_JOBS=2
Davide Pesavento97242f72020-02-29 14:28:15 -050097 - |
98 : Enabling workarounds
99 case "${TRAVIS_CPU_ARCH},${COMPILER}" in
100 arm64,g++*)
101 # Avoid exceeding the per-job time limit
102 export DISABLE_HEADERS_CHECK=yes
103 ;;
104 ppc64le,g++-7)
105 # AddressSanitizer does not seem to be working
106 export DISABLE_ASAN=yes
107 ;;
108 *,clang++-8)
109 # https://bugs.llvm.org/show_bug.cgi?id=40808
110 export DISABLE_ASAN=yes
111 ;;
112 esac
Davide Pesavento71430482017-06-08 20:06:40 -0400113 - ${CXX:-c++} --version
114
Alexander Afanasyevb4500d92014-01-17 20:43:24 -0800115script:
Alexander Afanasyeva87e0a82014-10-21 14:09:19 -0400116 - ./.jenkins