aboutsummaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorToni Uhlig <matzeton@googlemail.com>2024-10-30 10:41:48 +0100
committerToni Uhlig <matzeton@googlemail.com>2024-11-02 12:05:07 +0100
commitddc96ba614e4f6d1cd4ea9526ae1ccc9d71b8f49 (patch)
tree6eeb778de7ee8714d776ca02ac8fe751734415dd /scripts
parent7b2cd268bffae7646d0de69da8b62f3f3972d29e (diff)
Adjusted SonarCloud config and CI
Signed-off-by: Toni Uhlig <matzeton@googlemail.com>
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/build-sonarcloud.sh20
1 files changed, 20 insertions, 0 deletions
diff --git a/scripts/build-sonarcloud.sh b/scripts/build-sonarcloud.sh
new file mode 100755
index 000000000..55a62c959
--- /dev/null
+++ b/scripts/build-sonarcloud.sh
@@ -0,0 +1,20 @@
+#!/usr/bin/env bash
+
+set -e
+set -x
+
+cd "$(dirname "${0}")/.."
+
+BUILD_DIR=./build-sonarcloud
+NUMBER_OF_PROCESSORS=$(nproc --all)
+mkdir "${BUILD_DIR}"
+cmake -S . -B "${BUILD_DIR}" \
+ -DCMAKE_EXPORT_COMPILE_COMMANDS=ON \
+ -DENABLE_COVERAGE=ON \
+ -DBUILD_NDPI=ON \
+ -DBUILD_EXAMPLES=ON \
+ -DENABLE_CURL=ON \
+ -DENABLE_ZLIB=ON \
+ -DNDPI_WITH_GCRYPT=OFF
+cmake --build "${BUILD_DIR}" -j ${NUMBER_OF_PROCESSORS} \
+ --config Release