aboutsummaryrefslogtreecommitdiff
path: root/buildtools
diff options
context:
space:
mode:
Diffstat (limited to 'buildtools')
-rwxr-xr-xbuildtools/steps/build_all_linux.sh30
1 files changed, 30 insertions, 0 deletions
diff --git a/buildtools/steps/build_all_linux.sh b/buildtools/steps/build_all_linux.sh
new file mode 100755
index 0000000..6c7a903
--- /dev/null
+++ b/buildtools/steps/build_all_linux.sh
@@ -0,0 +1,30 @@
+#!/bin/bash +x
+
+set -e
+
+# get number of CPU cores
+if [ -f /proc/cpuinfo ]; then
+ CPUS=`grep processor /proc/cpuinfo | wc -l`
+else
+ CPUS=1
+fi
+
+# Stackoverflow suggests jobs count of (CPU cores + 1) as a respectively good number!
+JOBS=`expr $CPUS + 1`
+
+# run make for all configs
+pushd "$(dirname "$0")/../../compiler/linux64-debug-gcc"
+make -j$JOBS
+popd
+
+pushd "$(dirname "$0")/../../compiler/linux64-release-gcc"
+make -j$JOBS
+popd
+
+pushd "$(dirname "$0")/../../compiler/linux64-checked-gcc"
+make -j$JOBS
+popd
+
+pushd "$(dirname "$0")/../../compiler/linux64-profile-gcc"
+make -j$JOBS
+popd