jjb: lttng-tools: Add PKG_CONFIG_PATH to build script
[lttng-ci.git] / scripts / common / coverity.sh
index e2282e1c3de73b67a6273adaa25d9888a277bb73..ac60db5b93c8cf36ee1c9c817aef46810fbde7cc 100755 (executable)
@@ -1,7 +1,7 @@
 #!/bin/bash -exu
 #
-# Copyright (C) 2015 - Michael Jeanson <mjeanson@efficios.com>
-#                      Jonathan Rajotte-Julien <jonathan.rajotte-julien@efficios.com>
+# Copyright (C) 2019 Michael Jeanson <mjeanson@efficios.com>
+# Copyright (C) 2015 Jonathan Rajotte-Julien <jonathan.rajotte-julien@efficios.com>
 #
 # This program is free software: you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -51,7 +51,7 @@ export TMPDIR
 
 case "$COVERITY_SCAN_PROJECT_NAME" in
 babeltrace)
-    CONF_OPTS="--enable-python-bindings --enable-python-bindings-doc"
+    CONF_OPTS="--enable-python-bindings --enable-python-bindings-doc --enable-python-plugins"
     BUILD_TYPE="autotools"
     ;;
 liburcu)
@@ -112,28 +112,8 @@ if [ -d "$WORKSPACE/src/linux" ]; then
        export KERNELDIR="$WORKSPACE/src/linux"
 fi
 
-# Hack to get coverity with gcc >= 7
-#
-# We have to define the _Float* types as those are not defined by coverity and as result
-# the codes linking agains those (pretty much anything linking against stdlib.h and math.h)
-# won't be covered.
-echo "
-#ifdef __cplusplus
-extern \"C\" {
-#endif
-
-#define _Float128 long double
-#define _Float64x long double
-#define _Float64 double
-#define _Float32x double
-#define _Float32 float
-
-#ifdef __cplusplus
-}
-#endif" >> /tmp/coverity.h
-
-export CPPFLAGS="-include /tmp/coverity.h ${CPPFLAGS:-}"
-
+# Enter the source directory
+cd "$SRCDIR"
 
 # Verify upload is permitted
 #  Added "--insecure" because Coverity can't be bothered to properly install SSL certificate chains
@@ -175,8 +155,6 @@ fi
 TOOL_DIR=$(find "$TOOL_BASE" -type d -name 'cov-analysis*')
 export PATH=$TOOL_DIR/bin:$PATH
 
-cd "$SRCDIR"
-
 COVERITY_SCAN_VERSION=$(git describe --always | sed 's|-|.|g')
 
 # Build
@@ -205,7 +183,7 @@ autotools)
 linux-rseq)
     make defconfig
     make -j"$NPROC" prepare
-    cov-build --dir "$RESULTS_DIR" $COVERITY_SCAN_BUILD_OPTIONS make -j"$NPROC" kernel/rseq.o kernel/cpu_opv.o V=1 KCPPFLAGS="$CPPFLAGS"
+    cov-build --dir "$RESULTS_DIR" $COVERITY_SCAN_BUILD_OPTIONS make -j"$NPROC" kernel/rseq.o kernel/do_on_cpu/core.o kernel/do_on_cpu/interpreter.o kernel/do_on_cpu/validate.o V=1
     ;;
 *)
     echo "Unsupported build type: $BUILD_TYPE"
This page took 0.024714 seconds and 4 git commands to generate.