X-Git-Url: https://git.gag.com/?p=fw%2Fcortex-toolchain;a=blobdiff_plain;f=summon-arm-toolchain;h=fe9e58ad4049f248c2e9b743ff79f943efdd2704;hp=afbcbe4a3485db4683a1e63f392fa1b3bd51ce19;hb=d1fe6940a33afa4d4dc83d1429bcb66c5740b967;hpb=7df1edb6a20980d0069d5fff5d119d7498259c8f diff --git a/summon-arm-toolchain b/summon-arm-toolchain index afbcbe4..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= @@ -69,7 +72,7 @@ if [ ${DEFAULT_TO_CORTEX_M3} == 0 ] ; then GCCFLAGS= else # To default to the Cortex-M3: - GCCFLAGS="--with-arch=armv7-m --with-mode=thumb" + GCCFLAGS="--with-arch=armv7-m --with-mode=thumb --with-float=soft" fi # Pull in the local configuration, if any @@ -291,9 +294,10 @@ if [ ! -e ${STAMPS}/${NEWLIB}.build ]; then --with-gnu-ld \ --disable-nls \ --disable-werror \ - --disable-newlib-supplied-syscalls + --disable-newlib-supplied-syscalls \ + --with-float=soft log "Building ${NEWLIB}" - make ${MAKEFLAGS} + make ${MAKEFLAGS} CFLAGS_FOR_TARGET="-msoft-float" CCASFLAGS="-msoft-float" install ${NEWLIB} install cd .. log "Cleaning up ${NEWLIB}"