[openwrt/openwrt] build: add SUBDIR_MAKE_DEBUG variable to make it easier to debug package makefiles

LEDE Commits lede-commits at lists.infradead.org
Thu Nov 4 08:59:38 PDT 2021


nbd pushed a commit to openwrt/openwrt.git, branch master:
https://git.openwrt.org/94b0849c19848beda9e1a215bcae0daac6927ff0

commit 94b0849c19848beda9e1a215bcae0daac6927ff0
Author: Felix Fietkau <nbd at nbd.name>
AuthorDate: Thu Nov 4 15:53:50 2021 +0100

    build: add SUBDIR_MAKE_DEBUG variable to make it easier to debug package makefiles
    
    Signed-off-by: Felix Fietkau <nbd at nbd.name>
---
 include/subdir.mk | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/include/subdir.mk b/include/subdir.mk
index d33b947fdf..155f493538 100644
--- a/include/subdir.mk
+++ b/include/subdir.mk
@@ -27,7 +27,7 @@ lastdir=$(word $(words $(subst /, ,$(1))),$(subst /, ,$(1)))
 diralias=$(if $(findstring $(1),$(call lastdir,$(1))),,$(call lastdir,$(1)))
 
 subdir_make_opts = \
-	-r -C $(1) \
+	$(if $(SUBDIR_MAKE_DEBUG),-d) -r -C $(1) \
 		BUILD_SUBDIR="$(1)" \
 		BUILD_VARIANT="$(4)" \
 		ALL_VARIANTS="$(5)"



More information about the lede-commits mailing list