]> git.ipfire.org Git - people/pmueller/ipfire-2.x.git/commitdiff
make.sh: Limit ninja to compute paralellism value
authorStefan Schantl <stefan.schantl@ipfire.org>
Sat, 26 Dec 2020 17:09:24 +0000 (18:09 +0100)
committerMichael Tremer <michael.tremer@ipfire.org>
Sun, 27 Dec 2020 10:31:04 +0000 (10:31 +0000)
Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
make.sh

diff --git a/make.sh b/make.sh
index 5b1e949c4ec67e471027b5f974b479057220fa2f..8dfc8897dd67e36274532996756c8d54b5515224 100755 (executable)
--- a/make.sh
+++ b/make.sh
@@ -220,6 +220,9 @@ configure_build() {
        # Use this as default PARALLELISM
        DEFAULT_PARALLELISM="${parallelism}"
 
+       # Limit lauched ninja build jobs to computed parallel value.
+       NINJAJOBS="${parallelism}"
+
        # Compression parameters
        # We use mode 8 for reasonable memory usage when decompressing
        # but with overall good compression
@@ -465,7 +468,7 @@ prepareenv() {
        # Setup environment
        set +h
        LC_ALL=POSIX
-       export LFS LC_ALL CFLAGS CXXFLAGS DEFAULT_PARALLELISM RUSTFLAGS
+       export LFS LC_ALL CFLAGS CXXFLAGS DEFAULT_PARALLELISM RUSTFLAGS NINJAJOBS
        unset CC CXX CPP LD_LIBRARY_PATH LD_PRELOAD
 
        # Make some extra directories