From 2c0b2f30252a8c1cad34120b83c2ca356fd2b569 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Mon, 27 Mar 2017 00:50:17 +0300 Subject: Read jobs number for make from JOBS variable in ci scripts. --- tools/ci/scripts/init.sh | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/tools/ci/scripts/init.sh b/tools/ci/scripts/init.sh index 77e03ec76..a2aac226e 100755 --- a/tools/ci/scripts/init.sh +++ b/tools/ci/scripts/init.sh @@ -184,15 +184,22 @@ function run_cmake { function run_make { rm $ERRFILE - echo "make -j2 V=0 $*" - make -j2 V=0 $* 2>$ERRFILE + if [ "$JOBS" == "" ]; + export JOBS=2 + fi + + echo "make -j${JOBS} V=0 $*" + make -j${JOBS} V=0 $* 2>$ERRFILE check_error $? } function run_make_check { rm $ERRFILE - echo "make -j2 V=0 check $*" - make -j2 V=0 check $* 2>$ERRFILE + if [ "$JOBS" == "" ]; + export JOBS=2 + fi + echo "make -j${JOBS} V=0 check $*" + make -j${JOBS} V=0 check $* 2>$ERRFILE export ERR=$? if [ "${ERR}" != 0 ]; then cat $ERRFILE -- cgit v1.2.3-70-g09d2