[PATCH 6/7] kbuild: add objectify

From: Sam Ravnborg
Date: Sat Sep 10 2005 - 15:35:57 EST


Use foo := $(call objectify, $(foo)) to prefix $(foo) with $(obj)/ unless
$(foo) is an absolute path.
For now no in-tree users - soon to come.

Signed-off-by: Sam Ravnborg <sam@xxxxxxxxxxxx>

---

scripts/Kbuild.include | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)

0a504f259c90fb41d3495d490fc9dbe2530c8749
diff --git a/scripts/Kbuild.include b/scripts/Kbuild.include
--- a/scripts/Kbuild.include
+++ b/scripts/Kbuild.include
@@ -49,6 +49,9 @@ build := -f $(if $(KBUILD_SRC),$(srctree
cmd = @$(if $($(quiet)cmd_$(1)),\
echo ' $(subst ','\'',$($(quiet)cmd_$(1)))' &&) $(cmd_$(1))

+# Add $(obj)/ for paths that is not absolute
+objectify = $(foreach o,$(1),$(if $(filter /%,$(o)),$(o),$(obj)/$(o)))
+
###
# if_changed - execute command if any prerequisite is newer than
# target, or command line has changed

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/