jenkins: Osmocom_Sanitizer build fails
nhofmeyr at sysmocom.de
Sun Jun 18 14:18:58 UTC 2017
Today I noticed that the Osmocom_Sanitizer build has been broken for a long
time, failing at libosmocore/src/viterbi_sse.c. But that seems like the fault
of the way the Osmocom_Sanitizer builds:
When I build libosmocore with --enable-sanitize, everything works out. When I
instead build with `make CFLAGS+="..."', some CFLAGS are dropped and the build
The working commandline is:
gcc -DHAVE_CONFIG_H -I. -I.. -I../include -I../include -fsanitize=address -fsanitize=undefined -Wall -g -O2 -fsanitize=address -fsanitize=undefined -msse3 -msse4.1 -MT viterbi_sse.lo -MD -MP -MF .deps/viterbi_sse.Tpo -c viterbi_sse.c -fPIC -DPIC -o .libs/viterbi_sse.o
The failing one is:
make CFLAGS+="-fsanitize=address -fsanitize=undefined" V=1
gcc -DHAVE_CONFIG_H -I. -I.. -I../include -I../include -fsanitize=address -fsanitize=undefined -Wall -fsanitize=address -fsanitize=undefined -MT viterbi_sse.lo -MD -MP -MF .deps/viterbi_sse.Tpo -c viterbi_sse.c -fPIC -DPIC -o .libs/viterbi_sse.o
i.e. in the failing build, these cmdline args are missing:
So it seems that the CFLAGS+="stuff" is not working as intended.
The alternative is to build with the ./configure --enable-sanitize, which I
added at some point. But not all libs have this switch, AFAIR. I have added
the --enable-sanitize configure option to libosmocore, and asked others to
follow up in other repositories in the same fashion. I think this hasn't worked
out everywhere yet.
Does it make sense to refresh the sanitize build effort?: switch the
Osmocom_Sanitizer build to using this configure flag and add it where it is
But I guess we should instead add the sanitize switch to each individual build
script for the various *osmo* build jobs and switch off the Osmocom_Sanitizer
I repeat myself, but adding --enable-sanitize is not a lot of effort.
I created https://osmocom.org/issues/2330
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 819 bytes
Desc: Digital signature
More information about the OpenBSC