3 # Jailhouse, a Linux-based partitioning hypervisor
5 # Copyright (c) Siemens AG, 2015
8 # Jan Kiszka <jan.kiszka@siemens.com>
10 # This work is licensed under the terms of the GNU GPL, version 2. See
11 # the COPYING file in the top-level directory.
14 curl -s https://scan.coverity.com/scripts/travisci_build_coverity_scan.sh \
15 -o ci/travisci_build_coverity_scan.sh.orig
17 # Patch the line that starts the build.
18 # We need to control this step via our build script.
19 sed 's/^COVERITY_UNSUPPORTED=1 cov-build --dir.*/ci\/build-all-configs.sh --cov \$RESULTS_DIR \$COV_BUILD_OPTIONS/' \
20 ci/travisci_build_coverity_scan.sh.orig > ci/travisci_build_coverity_scan.sh.step1
22 # Path the branch name into the description.
23 sed 's/^ --form description=.*/ --form description="Travis CI build (branch: \$TRAVIS_BRANCH)" \\/' \
24 ci/travisci_build_coverity_scan.sh.step1 > ci/travisci_build_coverity_scan.sh
26 # Check if the patch applied, bail out if not.
27 if diff -q ci/travisci_build_coverity_scan.sh.orig \
28 ci/travisci_build_coverity_scan.sh.step1 > /dev/null || \
29 diff -q ci/travisci_build_coverity_scan.sh.step1 \
30 ci/travisci_build_coverity_scan.sh > /dev/null; then
31 echo "Unable to patch Coverity script!"
35 # Run the patched scanner script.
36 . ci/travisci_build_coverity_scan.sh