diff options
author | Andrei Karas <akaras@inbox.ru> | 2017-03-27 00:50:17 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2017-03-27 00:50:17 +0300 |
commit | 2c0b2f30252a8c1cad34120b83c2ca356fd2b569 (patch) | |
tree | c1458a9e62530ee67e714e1e079b9f7568def80d | |
parent | f57dfa419bf83a6b6fad7fd4eebb4cbe460593a7 (diff) | |
download | manaverse-2c0b2f30252a8c1cad34120b83c2ca356fd2b569.tar.gz manaverse-2c0b2f30252a8c1cad34120b83c2ca356fd2b569.tar.bz2 manaverse-2c0b2f30252a8c1cad34120b83c2ca356fd2b569.tar.xz manaverse-2c0b2f30252a8c1cad34120b83c2ca356fd2b569.zip |
Read jobs number for make from JOBS variable in ci scripts.
-rwxr-xr-x | tools/ci/scripts/init.sh | 15 |
1 files 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 |