BUILD_TYPE="maven"
MVN_BIN="$HOME/tools/hudson.tasks.Maven_MavenInstallation/default/bin/mvn"
;;
+linux-rseq)
+ CONF_OPTS=""
+ BUILD_TYPE="linux-rseq"
+ ;;
*)
echo "Generic project, no configure options."
CONF_OPTS=""
COVERITY_SCAN_VERSION=$(git describe --always | sed 's|-|.|g')
-# Prepare build dir for autotools based projects
-if [ -f "./bootstrap" ]; then
- ./bootstrap
- ./configure $CONF_OPTS
-fi
-
# Build
echo -e "\033[33;1mRunning Coverity Scan Analysis Tool...\033[0m"
case "$BUILD_TYPE" in
clean verify
;;
autotools)
+ # Prepare build dir for autotools based projects
+ if [ -f "./bootstrap" ]; then
+ ./bootstrap
+ ./configure $CONF_OPTS
+ fi
+
cov-build --dir "$RESULTS_DIR" $COVERITY_SCAN_BUILD_OPTIONS make -j"$NPROC" V=1
;;
+linux-rseq)
+ make defconfig
+ cov-build --dir "$RESULTS_DIR" $COVERITY_SCAN_BUILD_OPTIONS make -j"$NPROC" kernel/rseq.o kernel/cpu_opv.o V=1
+ ;;
*)
echo "Unsupported build type: $BUILD_TYPE"
exit 1
"$UPLOAD_URL")
set -x
status_code=$(echo "$response" | sed -n '$p')
-if [ "$status_code" == "201" ]; then
+if [ "${status_code:0:1}" == "2" ]; then
echo -e "\033[33;1mCoverity Scan upload successful.\033[0m"
else
TEXT=$(echo "$response" | sed '$d')