summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPiotr Esden-Tempski <piotr@esden.net>2010-11-13 20:18:07 -0800
committerPiotr Esden-Tempski <piotr@esden.net>2010-11-13 20:24:45 -0800
commitd1fe6940a33afa4d4dc83d1429bcb66c5740b967 (patch)
tree16e76b5a2f3534da375fa54a3d074f9705c8d1a1
parent0beded154984260dded10b507e3a7052c69f2b78 (diff)
PARALLEL flag is now being set automatically based on available host cpu's.
-rwxr-xr-xsummon-arm-toolchain5
1 files changed, 4 insertions, 1 deletions
diff --git a/summon-arm-toolchain b/summon-arm-toolchain
index 8663c07..fe9e58a 100755
--- a/summon-arm-toolchain
+++ b/summon-arm-toolchain
@@ -20,7 +20,6 @@ set -e
##############################################################################
TARGET=arm-none-eabi # Or: TARGET=arm-elf
PREFIX=${HOME}/sat # Install location of your final toolchain
-PARALLEL= # Or: PARALLEL="-j 5" for 4 CPUs
DARWIN_OPT_PATH=/opt/local # Path in which MacPorts or Fink is installed
# Set to 'sudo' if you need superuser privileges while installing
SUDO=
@@ -62,6 +61,10 @@ LIBOPENSTM32=master
# Flags section
##############################################################################
+CPUS=$(getconf _NPROCESSORS_ONLN)
+PARALLEL=-j$((CPUS + 1))
+echo "${CPUS} cpu's detected running make with '${PARALLEL}' flag"
+
GDBFLAGS=
BINUTILFLAGS=