chore: remove output of script sha1sum from jjb scripts
[ci-management.git] / jjb / scripts / vpp / gcc-build.sh
index 488e8d7..1d81600 100644 (file)
@@ -1,6 +1,6 @@
 #!/bin/bash
 
-# Copyright (c) 2021 Cisco and/or its affiliates.
+# Copyright (c) 2022 Cisco and/or its affiliates.
 # Licensed under the Apache License, Version 2.0 (the "License");
 # you may not use this file except in compliance with the License.
 # You may obtain a copy of the License at:
@@ -25,9 +25,6 @@ DRYRUN="${DRYRUN:-}"
 BUILD_RESULT="SUCCESSFULLY COMPLETED"
 BUILD_ERROR=""
 RETVAL="0"
-
-echo "sha1sum of this script: ${0}"
-sha1sum $0
 export CC=gcc
 
 make_build_release_build_test_gcov_sanity() {
@@ -47,16 +44,24 @@ make_build_release_build_test_gcov_sanity() {
         BUILD_ERROR="FAILED 'make build'"
         return
     fi
+    if [ -n "${MAKE_PARALLEL_JOBS}" ] ; then
+        TEST_JOBS="${MAKE_PARALLEL_JOBS}"
+        echo "Testing VPP with ${TEST_JOBS} cores."
+    else
+        TEST_JOBS="auto"
+        echo "Testing VPP with automatically calculated number of cores. " \
+             "See test logs for the exact number."
+    fi
     # TODO: Add 'smoke test' env var to select smoke test cases
     #       then update this accordingly.  For now pick a few basic suites...
-    MAKE_TEST_SUITES="vlib vppinfra vpe_api vapi vom bihash"
+    MAKE_TEST_SUITES="vlib vppinfra vpe_api vapi cli bihash"
     for suite in $MAKE_TEST_SUITES ; do
-        if ! make UNATTENDED=yes GCOV_TESTS=1 TEST_JOBS=auto TEST=$suite test ; then
-            BUILD_ERROR="FAILED 'make GCOV_TESTS=1 TEST_JOBS=auto TEST=$suite test'!"
+        if ! make UNATTENDED=yes TESTS_GCOV=1 TEST_JOBS="$TEST_JOBS" TEST=$suite test ; then
+            BUILD_ERROR="FAILED 'make TESTS_GCOV=1 TEST_JOBS=$TEST_JOBS TEST=$suite test'!"
             return
         fi
-        if ! make UNATTENDED=yes GCOV_TESTS=1 TEST_JOBS=auto TEST=$suite test-debug ; then
-            BUILD_ERROR="FAILED 'make GCOV_TESTS=1 TEST_JOBS=auto TEST=$suite test-debug'!"
+        if ! make UNATTENDED=yes TESTS_GCOV=1 TEST_JOBS="$TEST_JOBS" TEST=$suite test-debug ; then
+            BUILD_ERROR="FAILED 'make TESTS_GCOV=1 TEST_JOBS=$TEST_JOBS TEST=$suite test-debug'!"
             return
         fi
     done