Allow to limit number of cores used for compilation
Some checks failed
ci/woodpecker/push/build Pipeline failed
Some checks failed
ci/woodpecker/push/build Pipeline failed
This commit is contained in:
@@ -508,9 +508,11 @@ xtchain_build()
|
||||
set -e
|
||||
|
||||
# Check number of CPU cores available
|
||||
: ${CORES:=$(sysctl -n hw.ncpu 2>/dev/null)}
|
||||
: ${CORES:=$(nproc 2>/dev/null)}
|
||||
: ${CORES:=1}
|
||||
if [[ ! -n ${CORES} ]]; then
|
||||
: ${CORES:=$(sysctl -n hw.ncpu 2>/dev/null)}
|
||||
: ${CORES:=$(nproc 2>/dev/null)}
|
||||
: ${CORES:=1}
|
||||
fi
|
||||
|
||||
# Create working directories
|
||||
mkdir -p ${BINDIR}
|
||||
|
||||
Reference in New Issue
Block a user