Skip to content

Commit 9a86a48

Browse files
kaoudiscmeister2
authored andcommitted
coverage: clean possible mainline runs before collecting coverage
If the Makefile has already been generated, things might have been configured and built using clang, which also means ASan symbols that GCC will not like will be around. Clean the repository with distclean before running if signs of previous compilations are present.
1 parent 8c348ec commit 9a86a48

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

codecoverage.sh

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,14 @@ OPENSSLDIR=/tmp/openssl
1818
NGHTTPDIR=/tmp/nghttp2
1919
INSTALLDIR=/tmp/curlcov_install
2020

21+
# mainline.sh and codecoverage.sh use different compilers and the ASAN and
22+
# other LLVM specific things don't work with GCC so make sure we clean up
23+
# if there have been earlier mainline runs locally
24+
if [[ -d .deps/ && -f Makefile ]]
25+
then
26+
make distclean
27+
fi
28+
2129
# Install openssl
2230
${SCRIPTDIR}/handle_x.sh openssl ${OPENSSLDIR} ${INSTALLDIR} || exit 1
2331

0 commit comments

Comments
 (0)