forked from pocoproject/poco
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
293 lines (268 loc) · 11 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
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
language: cpp
cache:
- apt
services:
- mongodb
- redis
- postgresql
- mysql
addons:
postgresql: "9.4"
git:
submodules: false
notifications:
slack:
secure: "EKysuMlTU3Uv5XFX+zuwHK/ej4wtD8+UjO5xvchCFMkRgM0V3rERVT1rV6NocNBH4hjTcvue9DEKdWAtqdDh06vTOHGKdnZ/e204jA38HfcIA0SPVbQXzjckQXALvKl51OPOmGuI7Feo4wyohzUyGoDLo1bom02xqDfC3caQB5Q="
jobs:
include:
- name: Android (API level 19)
os: linux
dist: bionic
arch: amd64
addons:
apt:
packages:
- openjdk-8-jdk
before_install:
- export JAVA_HOME=/usr/lib/jvm/java-8-openjdk-amd64
- wget https://dl.google.com/android/repository/sdk-tools-linux-4333796.zip
- unzip -qq sdk-tools-linux-4333796.zip -d /opt/android-sdk
- rm sdk-tools-linux-4333796.zip
- echo "y" | /opt/android-sdk/tools/bin/sdkmanager "platform-tools" "system-images;android-24;default;armeabi-v7a" "platforms;android-24" "emulator" "ndk-bundle" "cmake;3.10.2.4988404" > /dev/null
before_script:
- export TERM=dumb
- export _NO_CHECK_SIGNATURE=true
- export ANDROID_SDK_ROOT=/opt/android-sdk
- echo no | /opt/android-sdk/tools/bin/avdmanager create avd -n test -k "system-images;android-24;default;armeabi-v7a"
- /opt/android-sdk/emulator/emulator -avd test -no-audio -no-window -dns-server 8.8.8.8 &
#- android-wait-for-emulator || android-wait-for-emulator
- /opt/android-sdk/platform-tools/adb shell input keyevent 82 &
script:
# Mandatory cmake parameter to set API level and platform for the android toolchain:
# /usr/local/android-sdk/cmake/3.6.4111459/bin/cmake -DCMAKE_TOOLCHAIN_FILE=/usr/local/android-sdk/ndk-bundle/build/cmake/android.toolchain.cmake -DANDROID_ABI=armeabi-v7a -DANDROID_PLATFORM=android-22
# See also in /usr/local/android-sdk/ndk-bundle/build/cmake/android.toolchain.cmake
# Using the ninja build command. Is much faster then make build command.
- /opt/android-sdk/cmake/3.10.2.4988404/bin/cmake -H. -Bcmake-build -GNinja -DANDROID_ABI=armeabi-v7a -DCMAKE_BUILD_TYPE=Release -DCMAKE_TOOLCHAIN_FILE=/opt/android-sdk/ndk-bundle/build/cmake/android.toolchain.cmake -DANDROID_PLATFORM=android-19 -DCMAKE_MAKE_PROGRAM=/opt/android-sdk/cmake/3.10.2.4988404/bin/ninja -DANDROID_STL="c++_static" -DANDROID_CPP_FEATURES="exceptions rtti" -DENABLE_APACHECONNECTOR=OFF -DENABLE_NETSSL=OFF -DENABLE_CRYPTO=OFF -DENABLE_JWT=OFF -DENABLE_DATA_MYSQL=OFF -DENABLE_DATA_POSTGRESQL=OFF -DENABLE_TESTS=ON -DENABLE_LONG_RUNNING_TESTS=OFF -DOLD_REDIS_VERSION=ON &&
/opt/android-sdk/cmake/3.10.2.4988404/bin/cmake --build cmake-build --target all #&&
#cd cmake-build && travis_wait 30 /opt/android-sdk/cmake/3.10.2.4988404/bin/ctest -E Foundation --output-on-failure FIXME Android emulator hangs
- name: Android (API level 24 arm64-v8a)
os: linux
dist: bionic
arch: amd64
addons:
apt:
packages:
- openjdk-8-jdk
before_install:
- export JAVA_HOME=/usr/lib/jvm/java-8-openjdk-amd64
- wget https://dl.google.com/android/repository/sdk-tools-linux-4333796.zip
- unzip -qq sdk-tools-linux-4333796.zip -d /opt/android-sdk
- rm sdk-tools-linux-4333796.zip
- echo "y" | /opt/android-sdk/tools/bin/sdkmanager "platform-tools" "system-images;android-24;default;arm64-v8a" "platforms;android-24" "emulator" "ndk-bundle" "cmake;3.10.2.4988404" > /dev/null
before_script:
- export TERM=dumb
- export _NO_CHECK_SIGNATURE=true
- export ANDROID_SDK_ROOT=/opt/android-sdk
- echo no | /opt/android-sdk/tools/bin/avdmanager create avd -n test -k "system-images;android-24;default;arm64-v8a"
- /opt/android-sdk/emulator/emulator -avd test -no-audio -no-window -dns-server 8.8.8.8 &
#- android-wait-for-emulator || android-wait-for-emulator
- /opt/android-sdk/platform-tools/adb shell input keyevent 82 &
script:
# Mandatory cmake parameter to set API level and platform for the android toolchain:
# /usr/local/android-sdk/cmake/3.6.4111459/bin/cmake -DCMAKE_TOOLCHAIN_FILE=/usr/local/android-sdk/ndk-bundle/build/cmake/android.toolchain.cmake -DANDROID_ABI=armeabi-v7a -DANDROID_PLATFORM=android-22
# See also in /usr/local/android-sdk/ndk-bundle/build/cmake/android.toolchain.cmake
# Using the ninja build command. Is much faster then make build command.
- /opt/android-sdk/cmake/3.10.2.4988404/bin/cmake -H. -Bcmake-build -GNinja -DANDROID_ABI=arm64-v8a -DCMAKE_BUILD_TYPE=Release -DCMAKE_TOOLCHAIN_FILE=/opt/android-sdk/ndk-bundle/build/cmake/android.toolchain.cmake -DANDROID_PLATFORM=android-24 -DCMAKE_MAKE_PROGRAM=/opt/android-sdk/cmake/3.10.2.4988404/bin/ninja -DANDROID_STL="c++_static" -DANDROID_CPP_FEATURES="exceptions rtti" -DENABLE_APACHECONNECTOR=OFF -DENABLE_NETSSL=OFF -DENABLE_CRYPTO=OFF -DENABLE_JWT=OFF -DENABLE_DATA_MYSQL=OFF -DENABLE_DATA_POSTGRESQL=OFF -DENABLE_TESTS=ON -DENABLE_LONG_RUNNING_TESTS=OFF -DOLD_REDIS_VERSION=ON &&
/opt/android-sdk/cmake/3.10.2.4988404/bin/cmake --build cmake-build --target all #&&
#cd cmake-build && travis_wait 30 /opt/android-sdk/cmake/3.10.2.4988404/bin/ctest -E Foundation --output-on-failure FIXME Android emulator hangs
- name: Linux (clang, make)
os: linux
dist: bionic
arch: amd64
addons:
apt:
packages:
- libssl-dev
- unixodbc-dev
- libmysqlclient-dev
compiler: clang
script:
- ./configure --everything --omit=PDF --config=Linux-clang && make all -s -j2 && sudo make install
- sudo -s ./travis/runtests.sh
- name: Linux (gcc, make)
os: linux
dist: bionic
arch: amd64
addons:
apt:
packages:
- libssl-dev
- unixodbc-dev
- libmysqlclient-dev
compiler: gcc
script:
- ./configure --everything --omit=PDF && make all -s -j2 && sudo make install
- sudo -s ./travis/runtests.sh
- name: Linux (gcc, make, arm64)
os: linux
dist: bionic
arch: arm64
addons:
apt:
packages:
- libssl-dev
compiler: gcc
script:
# skip some libs due to build timeout
- ./configure --everything --omit=PDF,Data/MySQL,Data/ODBC,Data/PostgreSQL,MongoDB,Redis && make all -s -j2 && sudo make install
- sudo -s ./travis/runtests.sh
- name: Linux (gcc, make, ppc64le)
os: linux
dist: bionic
arch: ppc64le
addons:
apt:
packages:
- libssl-dev
- libmysqlclient-dev
compiler: gcc
script:
- ./configure --everything --omit=PDF,Data/ODBC,Data/PostgreSQL,Redis && make all -s -j2 && sudo make install
- sudo -s ./travis/runtests.sh
- name: Linux (gcc, make, s390x)
os: linux
dist: bionic
arch: s390x
addons:
apt:
packages:
- libssl-dev
- unixodbc-dev
- libmysqlclient-dev
compiler: gcc
script:
- ./configure --everything --omit=PDF,Redis && make all -s -j2 && sudo make install
- sudo -s ./travis/runtests.sh
- name: macOS (clang, make)
os: osx
osx_image: xcode11.3
addons:
homebrew:
packages:
- openssl
script:
- ./configure --everything --no-prefix --omit=PDF,Data/MySQL,Data/ODBC,Data/PostgreSQL,Redis && make all -s -j2 && sudo make install
# ignore test results for now as timing-sensitive tests fail randomly
- sudo -s ./travis/runtests.sh || true
- name: Linux (gcc, cmake)
os: linux
dist: bionic
arch: amd64
compiler: gcc
addons:
apt:
packages:
- cmake
- ninja-build
- libssl-dev
- unixodbc-dev
- libmysqlclient-dev
script:
- cmake -H. -Bcmake-build -GNinja -DENABLE_PDF=OFF -DENABLE_TESTS=ON && cmake --build cmake-build --target all && cd cmake-build && sudo -s PWD=`pwd` ctest --output-on-failure -E "(DataMySQL)|(DataODBC)"
- name: Linux (clang, cmake)
os: linux
dist: bionic
arch: amd64
compiler: clang
addons:
apt:
packages:
- cmake
- ninja-build
- libssl-dev
- unixodbc-dev
- libmysqlclient-dev
script:
- cmake -H. -Bcmake-build -GNinja -DENABLE_PDF=OFF -DENABLE_TESTS=ON && cmake --build cmake-build --target all && cd cmake-build && sudo -s PWD=`pwd` ctest --output-on-failure -E "(DataMySQL)|(DataODBC)"
- name: Linux cross (arm-linux-gnueabi-g++, cmake)
os: linux
dist: bionic
arch: amd64
addons:
apt:
packages:
- cmake
- ninja-build
- libssl-dev
- unixodbc-dev
- libmysqlclient-dev
- g++-arm-linux-gnueabi
script:
- export CC="arm-linux-gnueabi-gcc"
- export CXX="arm-linux-gnueabi-g++"
- cmake -H. -Bcmake-build -GNinja -DENABLE_PDF=OFF -DENABLE_NETSSL=OFF -DENABLE_CRYPTO=OFF -DENABLE_JWT=OFF -DENABLE_TESTS=ON && cmake --build cmake-build --target all
- name: Linux cross (arm-linux-gnueabihf-g++, cmake)
os: linux
dist: bionic
arch: amd64
addons:
apt:
packages:
- cmake
- ninja-build
- libssl-dev
- unixodbc-dev
- libmysqlclient-dev
- g++-arm-linux-gnueabihf
script:
- export CC="arm-linux-gnueabihf-gcc"
- export CXX="arm-linux-gnueabihf-g++"
- cmake -H. -Bcmake-build -GNinja -DENABLE_PDF=OFF -DENABLE_NETSSL=OFF -DENABLE_CRYPTO=OFF -DENABLE_JWT=OFF -DENABLE_TESTS=ON && cmake --build cmake-build --target all
# build documentation and release
- name: Documentation & Release
os: linux
dist: bionic
arch: amd64
compiler: clang
script:
- . env.sh && mkdoc all && mkrel all
- ls -l releases
# QA jobs for code analytics and metrics
# static code analysis with cppcheck (we can add --enable=all later)
- name: CppCheck
os: linux
dist: bionic
arch: amd64
addons:
apt:
packages:
- cppcheck
script: cppcheck --force --quiet --inline-suppr -j2 -iData/SQLite/src/sqlite3.c .
# search for TODO within source tree
- name: TODO
os: linux
dist: bionic
arch: amd64
script: grep -r TODO *
# search for FIXME within source tree
- name: FIXME
os: linux
dist: bionic
arch: amd64
script: grep -r FIXME *
# search for HACK within source tree
- name: HACK
os: linux
dist: bionic
arch: amd64
script: grep -r HACK *
# some statistics about the code base
- name: Sloccount
os: linux
dist: bionic
arch: amd64
addons:
apt:
packages:
- sloccount
script: sloccount .