aboutsummaryrefslogtreecommitdiffstats
path: root/include/subdir.mk
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2008-06-09 15:38:45 +0000
committerFelix Fietkau <nbd@openwrt.org>2008-06-09 15:38:45 +0000
commit4c665e6ca4ce7044fbaf4e6a772b021c012f760c (patch)
tree2c5c0574cfda7d10c196399fd2791f5b57004f7b /include/subdir.mk
parent21e09858f13eb471582ca09f1ce306a004203fb2 (diff)
downloadupstream-4c665e6ca4ce7044fbaf4e6a772b021c012f760c.tar.gz
upstream-4c665e6ca4ce7044fbaf4e6a772b021c012f760c.tar.bz2
upstream-4c665e6ca4ce7044fbaf4e6a772b021c012f760c.zip
large improvement for parallel builds. works without V=99 now and without warnings. tested with -j on an 2x dual core opteron machine
SVN-Revision: 11414
Diffstat (limited to 'include/subdir.mk')
-rw-r--r--include/subdir.mk4
1 files changed, 2 insertions, 2 deletions
diff --git a/include/subdir.mk b/include/subdir.mk
index 3097ea418d..e12799b475 100644
--- a/include/subdir.mk
+++ b/include/subdir.mk
@@ -28,8 +28,8 @@ define subdir
$(call warn,$(1),d,BD $(1)/$(bd))
$(foreach target,$(SUBTARGETS),
$(call warn_eval,$(1)/$(bd),t,T,$(1)/$(bd)/$(target): $(if $(QUILT),,$($(1)/$(bd)/$(target)) $(call $(1)//$(target),$(1)/$(bd))))
- +$$(MAKE) -j1 -C $(1)/$(bd) $(target) $(if $(findstring $(bd),$($(1)/builddirs-ignore-$(target))), || $(call MESSAGE, ERROR: $(1)/$(bd) failed to build.))
-
+ $(if $(findstring $(bd),$($(1)/builddirs-parallel)),$$(SUBMAKE),$$(_SINGLE)$$(SUBMAKE) -j1) \
+ -C $(1)/$(bd) $(target) $(if $(findstring $(bd),$($(1)/builddirs-ignore-$(target))), || $(call MESSAGE, ERROR: $(1)/$(bd) failed to build.))
$$(if $(call debug,$(1)/$(bd),v),,.SILENT: $(1)/$(bd)/$(target))
# legacy targets