aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rwxr-xr-xtests/travis/build-and-test10
1 files changed, 8 insertions, 2 deletions
diff --git a/tests/travis/build-and-test b/tests/travis/build-and-test
index ba766999..65972231 100755
--- a/tests/travis/build-and-test
+++ b/tests/travis/build-and-test
@@ -1,6 +1,7 @@
#!/bin/sh
set -e
+HOST_SYSTEM=$(uname -s)
CMAKE_ARGS="-DBUILD_TESTS:BOOL=True"
case "$CONFIG" in
@@ -15,7 +16,7 @@ case "$CONFIG" in
;;
esac
-if [ "$(uname -s)" = "Darwin" ]; then
+if [ $HOST_SYSTEM = "Darwin" ]; then
# pick up cmake files from homebrew
CMAKE_ARGS="$CMAKE_ARGS -DCMAKE_PREFIX_PATH=/usr/local/opt/qt5"
else
@@ -33,7 +34,12 @@ fi
mkdir build
cd build
cmake .. $CMAKE_ARGS
-make -k
+
+if [ $HOST_SYSTEM = "Darwin" ]; then
+ make -k -j$(sysctl -n hw.logicalcpu)
+else
+ make -k -j$(nproc)
+fi
# run tests
make test