summaryrefslogtreecommitdiff
path: root/mk/build
diff options
context:
space:
mode:
authordholland <dholland@pkgsrc.org>2019-03-17 03:59:11 +0000
committerdholland <dholland@pkgsrc.org>2019-03-17 03:59:11 +0000
commit98a976c5f9ebcc364f2cc9cad887e79cf9497620 (patch)
treec08ec8a8aba9ec8feab549f9af9c940682185006 /mk/build
parentefbc4edb868cff34cc93a49a824a35d1224a8100 (diff)
downloadpkgsrc-98a976c5f9ebcc364f2cc9cad887e79cf9497620.tar.gz
Add support for MAKE_JOBS.pkgpath.
This allows setting MAKE_JOBS high and then setting e.g. MAKE_JOBS.emulators/qemu=2 (or some such low value) to keep it from thrashing during build. Discussed/approved on tech-pkg two months ago and then I forgot to actually commit it.
Diffstat (limited to 'mk/build')
-rw-r--r--mk/build/build.mk4
1 files changed, 3 insertions, 1 deletions
diff --git a/mk/build/build.mk b/mk/build/build.mk
index aa9dbffec9a..012cd92f67f 100644
--- a/mk/build/build.mk
+++ b/mk/build/build.mk
@@ -1,4 +1,4 @@
-# $NetBSD: build.mk,v 1.24 2018/11/30 18:38:19 rillig Exp $
+# $NetBSD: build.mk,v 1.25 2019/03/17 03:59:11 dholland Exp $
#
# This file defines what happens in the build phase, excluding the
# self-test, which is defined in test.mk.
@@ -55,6 +55,8 @@ BUILD_MAKE_CMD= \
.if defined(MAKE_JOBS_SAFE) && !empty(MAKE_JOBS_SAFE:M[nN][oO])
_MAKE_JOBS= # nothing
+.elif defined(MAKE_JOBS.${PKGPATH})
+_MAKE_JOBS= -j${MAKE_JOBS.${PKGPATH}}
.elif defined(MAKE_JOBS)
_MAKE_JOBS= -j${MAKE_JOBS}
.endif