mirror of
https://github.com/apache/nuttx.git
synced 2026-05-31 14:27:37 +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:
@@ -207,7 +207,7 @@ export_startup: board/libboard$(LIBEXT) $(STARTUP_OBJS)
|
||||
|
||||
# Build dependencies
|
||||
|
||||
.depend: Makefile asm_mem.h chip/Make.defs $(DEPSRCS)
|
||||
.depend: Makefile asm_mem.h chip/Make.defs $(DEPSRCS) $(TOPDIR)$(DELIM).config
|
||||
$(Q) if [ -e board/Makefile ]; then \
|
||||
$(MAKE) -C board TOPDIR="$(TOPDIR)" depend ; \
|
||||
fi
|
||||
|
||||
@@ -201,7 +201,7 @@ export_startup: board\libboard$(LIBEXT) $(STARTUP_OBJS)
|
||||
|
||||
# Build dependencies
|
||||
|
||||
.depend: Makefile asm_mem.h chip\Make.defs $(DEPSRCS)
|
||||
.depend: Makefile asm_mem.h chip\Make.defs $(DEPSRCS) $(TOPDIR)$(DELIM).config
|
||||
$(Q) if exist board\Makefile ( $(MAKE) -C board TOPDIR="$(TOPDIR)" depend )
|
||||
$(Q) $(MKDEP) --dep-path chip --dep-path common "$(CC)" -- $(CFLAGS) -- $(DEPSRCS) >Make.dep
|
||||
$(Q) touch $@
|
||||
|
||||
@@ -137,7 +137,7 @@ nuttx$(EXEEXT): $(HEAD_OBJ) board$(DELIM)libboard$(LIBEXT) nuttx.linkcmd
|
||||
@echo "LD: nuttx$(EXEEXT)"
|
||||
$(Q) "$(LD)" $(LDFLAGS)
|
||||
|
||||
.depend: Makefile chip$(DELIM)Make.defs $(DEPSRCS)
|
||||
.depend: Makefile chip$(DELIM)Make.defs $(DEPSRCS) $(TOPDIR)$(DELIM).config
|
||||
$(Q) if [ -e board$(DELIM)Makefile ]; then \
|
||||
$(MAKE) -C board TOPDIR="$(TOPDIR)" depend ; \
|
||||
fi
|
||||
|
||||
@@ -126,7 +126,7 @@ nuttx$(EXEEXT): $(HEAD_OBJ) board$(DELIM)libboard$(LIBEXT) nuttx.linkcmd
|
||||
@echo "LD: nuttx$(EXEEXT)"
|
||||
$(Q) "$(LD)" $(LDFLAGS)
|
||||
|
||||
.depend: Makefile chip$(DELIM)Make.defs $(DEPSRCS)
|
||||
.depend: Makefile chip$(DELIM)Make.defs $(DEPSRCS) $(TOPDIR)$(DELIM).config
|
||||
$(Q) if exist board$(DELIM)Makefile ( $(MAKE) -C board TOPDIR="$(TOPDIR)" depend )
|
||||
$(Q) $(MKDEP) --dep-path chip --dep-path common "$(CC)" -- $(CFLAGS) -- $(DEPSRCS) >Make.dep
|
||||
$(Q) touch $@
|
||||
|
||||
Reference in New Issue
Block a user