mirror of
https://github.com/apache/nuttx.git
synced 2026-06-07 01:05:54 +08:00
Makefile: Fix Make.dep not updated by config changes
Make.dep file should be updated by .config changed after first make. There are 2 cases affected for this problem: 1) Add source files by config symbol 2) Include header files in #ifdef directive These 2 cases may not be included in Make.dep and this may prevent the differential build from working correctly.
This commit is contained in:
+1
-1
@@ -154,7 +154,7 @@ endif
|
||||
|
||||
# Dependencies
|
||||
|
||||
.depend: Makefile $(SRCS)
|
||||
.depend: Makefile $(SRCS) $(TOPDIR)$(DELIM).config
|
||||
$(Q) $(MKDEP) --obj-path bin --obj-suffix $(OBJEXT) $(DEPPATH) "$(CC)" -- $(CFLAGS) -- $(SRCS) >bin/Make.dep
|
||||
ifneq ($(CONFIG_BUILD_FLAT),y)
|
||||
$(Q) $(MKDEP) --obj-path kbin --obj-suffix $(OBJEXT) $(DEPPATH) "$(CC)" -- $(CFLAGS) $(KDEFINE) -- $(SRCS) >kbin/Make.dep
|
||||
|
||||
@@ -118,7 +118,7 @@ context: .tzbuilt romfs
|
||||
|
||||
# Create dependencies
|
||||
|
||||
.depend: Makefile $(SRCS)
|
||||
.depend: Makefile $(SRCS) $(TOPDIR)$(DELIM).config
|
||||
$(Q) $(MKDEP) "$(CC)" -- $(CFLAGS) -- $(SRCS) >Make.dep
|
||||
$(Q) touch $@
|
||||
|
||||
|
||||
@@ -65,7 +65,7 @@ $(COBJS): %$(OBJEXT): %.c
|
||||
$(BIN): $(OBJS)
|
||||
$(call ARCHIVE, $@, $(OBJS))
|
||||
|
||||
.depend: Makefile $(SRCS)
|
||||
.depend: Makefile $(SRCS) $(TOPDIR)$(DELIM).config
|
||||
$(Q) $(MKDEP) $(DEPPATH) "$(CC)" -- $(CFLAGS) -- $(SRCS) >Make.dep
|
||||
$(Q) touch $@
|
||||
|
||||
|
||||
+1
-1
@@ -235,7 +235,7 @@ endif
|
||||
|
||||
# Dependencies
|
||||
|
||||
.depend: Makefile gensources $(SRCS)
|
||||
.depend: Makefile gensources $(SRCS) $(TOPDIR)$(DELIM).config
|
||||
$(Q) $(MKDEP) --obj-path bin --obj-suffix $(OBJEXT) $(DEPPATH) "$(CC)" -- $(CFLAGS) -- $(SRCS) >bin/Make.dep
|
||||
ifneq ($(CONFIG_BUILD_FLAT),y)
|
||||
$(Q) $(MKDEP) --obj-path kbin --obj-suffix $(OBJEXT) $(DEPPATH) "$(CC)" -- $(CFLAGS) $(KDEFINE) -- $(SRCS) >kbin/Make.dep
|
||||
|
||||
+1
-1
@@ -87,7 +87,7 @@ $(BIN): $(OBJS)
|
||||
|
||||
dirlinks::
|
||||
|
||||
.depend: Makefile $(SRCS)
|
||||
.depend: Makefile $(SRCS) $(TOPDIR)$(DELIM).config
|
||||
$(Q) $(MKDEP) $(DEPPATH) "$(CXX)" -- $(CXXFLAGS) -- $(SRCS) >Make.dep
|
||||
$(Q) touch $@
|
||||
|
||||
|
||||
Reference in New Issue
Block a user