@@ -35,21 +35,22 @@ compile_template: &COMPILE
35
35
if test "$USE_CONFIG" = "yes"; then
36
36
MAKE_OPTS=
37
37
autoreconf -i
38
- eval ./configure --enable-plugins --enable-werror $CONFIG_OPTS CFLAGS=\"-g -O3 $CFLAGS\" || \
38
+ eval ./configure --enable-plugins --enable-werror $CONFIG_OPTS CFLAGS=\"$CFLAGS\" || \
39
39
( cat config.log; false )
40
40
else
41
41
MAKE_OPTS=-e
42
42
fi
43
+ make cc-version $MAKE_OPTS
43
44
if test "x$DO_MAINTAINER_CHECKS" = "xyes"; then
44
- make maintainer-check
45
+ make maintainer-check $MAKE_OPTS
45
46
fi
46
47
make -j 4 $MAKE_OPTS
47
48
48
49
test_template : &TEST
49
50
test_script : |
50
- make test-shlib-exports
51
- make test
52
- if test "x$DO_UNTRACKED_FILE_CHECK" = "xyes"; then make check-untracked ; fi
51
+ make test-shlib-exports $MAKE_OPTS
52
+ make test $MAKE_OPTS
53
+ if test "x$DO_UNTRACKED_FILE_CHECK" = "xyes"; then make check-untracked $MAKE_OPTS ; fi
53
54
54
55
# --------------------------------------------------
55
56
# Task: linux builds.
@@ -71,10 +72,14 @@ gcc_task:
71
72
DO_MAINTAINER_CHECKS : yes
72
73
DO_UNTRACKED_FILE_CHECK : yes
73
74
USE_CONFIG : no
75
+ CFLAGS : -g -O2 -Wall -Werror -fvisibility=hidden
74
76
- environment :
75
77
USE_CONFIG : yes
76
- CFLAGS : -std=c99 -pedantic -Wformat=2
78
+ # ubsan is incompatible with some -Wformat opts so we do that on clang.
79
+ CFLAGS : -g -O3 -fsanitize=address,undefined -DHTS_ALLOW_UNALIGNED=0 -Wno-format-truncation -Wno-format-overflow
80
+ LDFLAGS : -fsanitize=address,undefined
77
81
USE_LIBDEFLATE : yes
82
+ UBSAN_OPTIONS : print_stacktrace=1:halt_on_error=1
78
83
79
84
install_script : |
80
85
apt-get update
@@ -105,11 +110,12 @@ ubuntu_task:
105
110
matrix :
106
111
- environment :
107
112
USE_CONFIG : yes
113
+ CFLAGS : -g -O3
108
114
DO_UNTRACKED_FILE_CHECK : yes
109
115
- environment :
116
+ # Cirrus-CI's clang isn't installed with ubsan, so we do that in gcc
110
117
USE_CONFIG : yes
111
- CFLAGS : -g -Wall -O3 -fsanitize=address
112
- LDFLAGS : -fsanitize=address
118
+ CFLAGS : -g -O3 -std=c99 -pedantic -Wall -Wformat -Wformat=2
113
119
USE_LIBDEFLATE : yes
114
120
115
121
# NB: we could consider building a docker image with these
@@ -137,7 +143,7 @@ rocky_task:
137
143
LC_ALL : C
138
144
CIRRUS_CLONE_DEPTH : 1
139
145
USE_CONFIG : yes
140
- CFLAGS : -std=gnu90
146
+ CFLAGS : -g -O3 - std=gnu90 -Wall -Wformat -Wformat=2 -Wextra -Wno-sign-compare -Wno-unused-parameter -Wno-missing-field-initializers
141
147
142
148
# NB: we could consider building a docker image with these
143
149
# preinstalled and specifying that instead, to speed up testing.
@@ -182,11 +188,10 @@ arm_ubuntu_task:
182
188
macosx_task :
183
189
name : macosx + clang
184
190
macos_instance :
185
- image : ghcr.io/cirruslabs/macos-ventura-base:latest
191
+ image : ghcr.io/cirruslabs/macos-runner:sonoma
186
192
187
193
environment :
188
194
CC : clang
189
- CFLAGS : " -Wall -arch arm64 -arch x86_64"
190
195
LDFLAGS : " -arch arm64 -arch x86_64"
191
196
LIBDEFLATE_CFLAGS : " -arch arm64 -arch x86_64"
192
197
LC_ALL : C
@@ -195,9 +200,11 @@ macosx_task:
195
200
matrix :
196
201
- environment :
197
202
USE_CONFIG : no
203
+ CFLAGS : " -g -O3 -Wall -Werror -arch arm64 -arch x86_64"
198
204
- environment :
199
205
USE_CONFIG : yes
200
206
USE_LIBDEFLATE : yes
207
+ CFLAGS : " -g -O3 -Wall -arch arm64 -arch x86_64"
201
208
202
209
package_install_script : |
203
210
HOMEBREW_NO_AUTO_UPDATE=1 brew install autoconf automake libtool xz git \
0 commit comments