From: vkargov Date: Mon, 22 May 2017 12:43:28 +0000 (-0700) Subject: [ci] Add the collect-coverage tag for use on Jenkins. (#4912) X-Git-Url: http://wien.tomnetworks.com/gitweb/?p=mono.git;a=commitdiff_plain;h=eb18b8c0deaaf90a7a9cf807693782cdafc801c1 [ci] Add the collect-coverage tag for use on Jenkins. (#4912) * [ci] Add the collect-coverage tag for use on Jenkins. * Move collect-coverage up so we don't set different values for -O --- diff --git a/scripts/ci/run-jenkins.sh b/scripts/ci/run-jenkins.sh index e87ea8838eb..a308f1b252b 100755 --- a/scripts/ci/run-jenkins.sh +++ b/scripts/ci/run-jenkins.sh @@ -5,7 +5,13 @@ export TESTCMD=${MONO_REPO_ROOT}/scripts/ci/run-step.sh export TEST_HARNESS_VERBOSE=1 -if [[ ${label} == w* ]]; then +if [[ $CI_TAGS == *'collect-coverage'* ]]; then + # Collect coverage for further use by lcov and similar tools. + # Coverage must be collected with -O0 and debug information. + export CFLAGS="-ggdb3 --coverage -O0" + # Collect coverage on all optimizations + export MONO_ENV_OPTIONS="$MONO_ENV_OPTIONS -O=all" +elif [[ ${label} == w* ]]; then # Passing -ggdb3 on Cygwin breaks linking against libmonosgen-x.y.dll export CFLAGS="-g -O2" else