summaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
authorRicardo Salveti <ricardo.salveti@linaro.org>2016-07-25 13:22:22 -0300
committerRicardo Salveti <ricardo.salveti@linaro.org>2016-07-25 13:23:50 -0300
commit7b53c036e6bf56623b8273018ff1c8cc62847857 (patch)
tree4af0da8c150bbebd7d1d252d6ac801a7efef0d23 /scripts
parent5d4e5dcd8a186778b3d78e27c81550d07a288fd2 (diff)
Imported Upstream version 16.07-rc4
Change-Id: Ic57f6a3726f2dbd1682223648d91310f45705327 Signed-off-by: Ricardo Salveti <ricardo.salveti@linaro.org>
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/validate-abi.sh15
1 files changed, 13 insertions, 2 deletions
diff --git a/scripts/validate-abi.sh b/scripts/validate-abi.sh
index c36ad61d..feda6c86 100755
--- a/scripts/validate-abi.sh
+++ b/scripts/validate-abi.sh
@@ -97,6 +97,17 @@ fixup_config() {
#trap on ctrl-c to clean up
trap cleanup_and_exit SIGINT
+if [ -z "$DPDK_MAKE_JOBS" ]
+then
+ # This counts the number of cpus on the system
+ if [ -e /usr/bin/lscpu ]
+ then
+ DPDK_MAKE_JOBS=`lscpu -p=cpu | grep -v "#" | wc -l`
+ else
+ DPDK_MAKE_JOBS=1
+ fi
+fi
+
#Save the current branch
CURRENT_BRANCH=`git branch | grep \* | cut -d' ' -f2`
@@ -183,7 +194,7 @@ log "INFO" "Configuring DPDK $TAG1"
make config T=$TARGET O=$TARGET > $VERBOSE 2>&1
log "INFO" "Building DPDK $TAG1. This might take a moment"
-make O=$TARGET > $VERBOSE 2>&1
+make -j$DPDK_MAKE_JOBS O=$TARGET > $VERBOSE 2>&1
if [ $? -ne 0 ]
then
@@ -214,7 +225,7 @@ log "INFO" "Configuring DPDK $TAG2"
make config T=$TARGET O=$TARGET > $VERBOSE 2>&1
log "INFO" "Building DPDK $TAG2. This might take a moment"
-make O=$TARGET > $VERBOSE 2>&1
+make -j$DPDK_MAKE_JOBS O=$TARGET > $VERBOSE 2>&1
if [ $? -ne 0 ]
then