From: Jason Ish Date: Tue, 13 Feb 2024 19:38:57 +0000 (-0600) Subject: cocci/run-check: log if parallel command is not found X-Git-Tag: suricata-8.0.0-beta1~1739 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f7114b7fe38861f1dc618586158617f9b1c14ddd;p=thirdparty%2Fsuricata.git cocci/run-check: log if parallel command is not found If CONCURRENCY_LEVEL was set, the script would log a concurrency level even if the parallel command was not available. Not log if parallel is not available and set concurrency to 1. --- diff --git a/qa/coccinelle/run_check.sh b/qa/coccinelle/run_check.sh index 325e1732fa..d9a451661b 100755 --- a/qa/coccinelle/run_check.sh +++ b/qa/coccinelle/run_check.sh @@ -29,9 +29,12 @@ else BUILT_COCCI_FILES="" fi -if [ -z "$CONCURRENCY_LEVEL" ]; then +if ! command -v parallel > /dev/null; then + echo "Concurrency disabled, command 'parallel' not available" + CONCURRENCY_LEVEL=1 +elif [ -z "$CONCURRENCY_LEVEL" ]; then + echo "No concurrency" CONCURRENCY_LEVEL=1 - echo "No concurrency" else echo "Using concurrency level $CONCURRENCY_LEVEL" fi