[02/11] nmk: Filter out already seen targets from collect-deps

Submitted by Cyrill Gorcunov on July 12, 2018, 12:51 p.m.

Details

Message ID 20180712125142.8737-3-gorcunov@gmail.com
State New
Series "build: Fix issue on simultaneous build"
Headers show

Commit Message

Cyrill Gorcunov July 12, 2018, 12:51 p.m.
Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
---
 scripts/nmk/scripts/build.mk | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Patch hide | download patch | download mbox

diff --git a/scripts/nmk/scripts/build.mk b/scripts/nmk/scripts/build.mk
index 890a912d09b0..f16af03f2519 100644
--- a/scripts/nmk/scripts/build.mk
+++ b/scripts/nmk/scripts/build.mk
@@ -261,7 +261,7 @@  define collect-deps
         ifeq ($(lib-target),$(1))
                 deps-y += $(lib-y:.o=.d)
         endif
-        ifneq ($(filter all $(all-y) $(hostprogs-y),$(1)),)
+        ifneq ($(filter all $(filter-out $(builtin-target) $(lib-target), $(all-y)) $(hostprogs-y),$(1)),)
                 deps-y += $(obj-y:.o=.d)
                 deps-y += $(lib-y:.o=.d)
                 deps-y += $(foreach t,$(target),$(call objectify,$($(t)-lib-y:.o=.d)) $(call objectify,$($(t)-obj-y:.o=.d)))