-
Notifications
You must be signed in to change notification settings - Fork 25
/
.travis.yml
184 lines (174 loc) · 4.94 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
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
version: ~> 1.0
language: cpp
dist: jammy
cache:
- ccache
- directories:
- $TRAVIS_BUILD_DIR/vcpkg
- $HOME/.cache/vcpkg/archives
# Don't double build branch PRs
branches:
except:
- /^pr\..*/
addons:
apt:
update: true
packages:
- build-essential
- automake
- autoconf
- autoconf-archive
- libtool-bin
- texinfo
- yasm
- gcc-12
- g++-12
- ninja-build
- cppcheck
- doxygen
- graphviz
- lcov
- valgrind
- ccache
- wget
os:
- linux
compiler:
- g++-12
- clang-19
jobs:
fast_finish: true
# include:
# # CppCheck
# - os: linux
# compiler: g++12
# env: CPPCHECK=true
# before_script:
# - export CMAKE_ARGS="-D ENABLE_CPPCHECK:BOOL=TRUE"
# after_success: skip
# # Valgrind
# - os: linux
# compiler: g++12
# env: VALGRIND=true
# before_script:
# - export CMAKE_ARGS="-D ENABLE_IPO:BOOL=FALSE -D ENABLE_VALGRIND:BOOL=TRUE"
# after_success:
# - cd $TRAVIS_BUILD_DIR/build/
# - travis_wait 60 ctest -VV -T memcheck --verbose
# - cd src
# - travis_wait 30 valgrind --leak-check=full --show-leak-kinds=all --verbose ./initialize --s -n32000 -t11 -o
# - travis_wait 30 valgrind --leak-check=full --show-leak-kinds=all --verbose ./cdt-opt
# - travis_wait 30 valgrind --leak-check=full --show-leak-kinds=all --verbose ./cdt --s -n64 -t3 -a0.6 -k1.1 -l0.1 -p10
# # AddressSanitizer and UndefinedBehaviorSanitizer
# - os: linux
# compiler: clang-15
# env: ASAN=true
# before_script:
# - export CMAKE_ARGS="-D ENABLE_SANITIZER_ADDRESS:BOOL=TRUE -D ENABLE_SANITIZER_UNDEFINED_BEHAVIOR:BOOL=TRUE"
# after_success:
# - cd $TRAVIS_BUILD_DIR/build/
# - ctest -VV
# - cd src
# - ./initialize --s -n32000 -t11 -o
# # LeakSanitizer
# - os: linux
# compiler: clang-15
# env: LSAN=true
# before_script:
# - export CMAKE_ARGS="-D ENABLE_SANITIZER_LEAK:BOOL=TRUE"
# after_success:
# - cd $TRAVIS_BUILD_DIR/build/
# - ctest -VV
# - cd src
# - ./initialize --s -n32000 -t11 -o
# # MemorySanitizer
# - os: linux
# compiler: clang-15
# env: MSAN=true
# before_script:
# - export CMAKE_ARGS="-D ENABLE_SANITIZER_MEMORY:BOOL=TRUE"
# after_success:
# - cd $TRAVIS_BUILD_DIR/build/
# - ctest -VV
# - cd src
# - ./initialize --s -n32000 -t11 -o
# # ThreadSanitizer
# - os: linux
# compiler: clang-15
# env: TSAN=true
# before_script:
# - export CMAKE_ARGS="-D ENABLE_SANITIZER_THREAD:BOOL=TRUE"
# after_success:
# - cd $TRAVIS_BUILD_DIR/build/
# - travis_wait 90 ctest -VV
# - cd src
# - ./initialize --s -n32000 -t11 -o
# # Doxygen
# - os: linux
# compiler: g++12
# env: DOXYGEN=true
# install: skip
# script:
# - cd $TRAVIS_BUILD_DIR
# - doxygen docs/Doxyfile
# - touch docs/html/.nojekyll
# after_success:
# # Overwrite usual after_success step without canceling it (which would cause deploy to not run)
# - pwd
# deploy:
# provider: pages
# skip_cleanup: true
# local_dir: docs/html
# github_token: $GITHUB_TOKEN
# keep_history: true
# verbose: true
# edge: true
# on:
# all_branches: true
# condition: $TRAVIS_BRANCH =~ ^(master|develop)$
# allow_failures:
# - os: linux
# compiler: g++12
# env: DOXYGEN=true
before_install:
- |
if [[ "$CXX" == "g++" ]]; then
sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-12 90
sudo update-alternatives --config gcc
export CXX="g++-12" CC="gcc-12"
fi
- |
if [[ "$CXX" == "clang++" ]]; then
wget https://apt.llvm.org/llvm.sh
chmod +x llvm.sh
sudo ./llvm.sh 19
sudo update-alternatives --install /usr/bin/clang clang /usr/bin/clang-19 100
sudo update-alternatives --install /usr/bin/clang++ clang++ /usr/bin/clang++-19 100
export CXX="clang++-19" CC="clang-19"
clang --version
clang++ --version
fi
install:
# vcpkg should be cached, but clone it if not
- |
if [[ ! -f vcpkg/vcpkg ]]; then
git clone https://github.com/Microsoft/vcpkg.git
fi
- export VCPKG_ROOT="$TRAVIS_BUILD_DIR/vcpkg"
- export PATH="$VCPKG_ROOT:$PATH"
- cd $VCPKG_ROOT
- git pull origin master --no-rebase
- ./bootstrap-vcpkg.sh
- rm -rf downloads buildtrees packages
- cmake --version
- cd ..
- pwd
# Install required libraries (these are often cached, so you must remove old dependencies first, as above)
- travis_wait 120 vcpkg install
- vcpkg list
script:
- cmake $CMAKE_ARGS -G Ninja -D CMAKE_BUILD_TYPE=RelWithDebInfo -D ENABLE_TESTING:BOOL=TRUE -S . -B build
- travis_wait 60 cmake --build build
after_success:
- cd build
- travis_wait 90 ctest --output-on-failure -j2