Skip to contentSkip to conversation

make sure toplevel $(SUBDIRS) is always declared

PATCH New Mike Frysinger 2 participants 2 messages May 30, 2009 – Jun 14, 2009 Kbuild

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 make sure toplevel $(SUBDIRS) is always declared

The $(SUBDIRS) variable is only declared when U-Boot has been configured, but it gets used all the time. In the non-configured case, it is used to generate a helpful error message, but it needs to be set properly for that to occur.

---
 Makefile |   16 ++++++++--------
 1 files changed, 8 insertions(+), 8 deletions(-)
Makefile +8 -8
index 81a5cd0..2ed1792 100644
@@ -137,6 +137,14 @@ ifeq ($(ARCH),powerpc)
 ARCH = ppc
 endif
 
+# The "tools" are needed early, so put this first
+# Don't include stuff already done in $(LIBS)
+SUBDIRS	= tools \
+	  examples \
+	  api_examples
+
+.PHONY : $(SUBDIRS)
+
 ifeq ($(obj)include/config.mk,$(wildcard $(obj)include/config.mk))
 
 # load ARCH, BOARD, and CPU configuration
@@ -282,14 +290,6 @@ LIBBOARD := $(addprefix $(obj),$(LIBBOARD))
 # Add GCC lib
 PLATFORM_LIBS += -L $(shell dirname `$(CC) $(CFLAGS) -print-libgcc-file-name`) -lgcc
 
-# The "tools" are needed early, so put this first
-# Don't include stuff already done in $(LIBS)
-SUBDIRS	= tools \
-	  examples \
-	  api_examples
-
-.PHONY : $(SUBDIRS)
-
 ifeq ($(CONFIG_NAND_U_BOOT),y)
 NAND_SPL = nand_spl
 U_BOOT_NAND = $(obj)u-boot-nand.bin
Signature · 1 line
1.6.3.1
#1 lore raw

PATCH 1/1 make sure toplevel $(SUBDIRS) is always declared

Dear Mike Frysinger,

Quoted 9 lines · In message <[email protected]> you wrote:

The $(SUBDIRS) variable is only declared when U-Boot has been configured, but it gets used all the time. In the non-configured case, it is used to generate a helpful error message, but it needs to be set properly for that to occur.

---
 Makefile |   16 ++++++++--------
 1 files changed, 8 insertions(+), 8 deletions(-)

Applied, thanks.

Best regards,

Wolfgang Denk

Signature · 5 lines
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
A committee is a life form with six or more legs and no brain.
                              -- Lazarus Long, "Time Enough For Love"