From c584d27c3c432a72b14e00cfb6b681c071791b32 Mon Sep 17 00:00:00 2001 From: Gregory Nutt Date: Fri, 2 Jun 2017 16:14:13 -0600 Subject: [PATCH] Revert "Build system: Hook tools/initconfig into top-level Makefiles." This reverts commit 430060e92e1fade7822f24135336dc26eb100b82. That commit has some unexpected side-effects --- Makefile.unix | 22 ++++++++++------------ Makefile.win | 17 +++++------------ tools/initialconfig.c | 5 ----- 3 files changed, 15 insertions(+), 29 deletions(-) diff --git a/Makefile.unix b/Makefile.unix index 8c36def651..8a88b5f9db 100644 --- a/Makefile.unix +++ b/Makefile.unix @@ -282,38 +282,36 @@ tools/cnvwindeps$(HOSTEXEEXT): # configured directories. Make.defs: +<<<<<<< HEAD $(Q) echo "No Make.defs file found, creating one" $(Q) echo "include $(TOPDIR)$(DELIM).config" > Make.defs $(Q) echo "include $(TOPDIR)$(DELIM)tools$(DELIM)Config.mk" >> Make.defs - -tools/initialconfig$(HOSTEXEEXT): - $(Q) $(MAKE) -C tools -f Makefile.host TOPDIR="$(TOPDIR)" initialconfig$(HOSTEXEEXT) - -.config: tools/initialconfig$(HOSTEXEEXT) - $(Q) echo "No .config file found, creating one" - $(Q) tools/initialconfig$(HOSTEXEEXT) +======= + echo "include $(TOPDIR)$(DELIM).config" > Make.defs + echo "include $(TOPDIR)$(DELIM)tools$(DELIM)Config.mk" >> Make.defs +>>>>>>> parent of 430060e92e... Build system: Hook tools/initconfig into top-level Makefiles. # Link the arch//include directory to include/arch -include/arch: .config Make.defs +include/arch: Make.defs @echo "LN: include/arch to $(ARCH_DIR)/include" $(Q) $(DIRLINK) $(TOPDIR)/$(ARCH_DIR)/include include/arch # Link the configs//include directory to include/arch/board -include/arch/board: include/arch +include/arch/board: include/arch Make.defs include/arch @echo "LN: include/arch/board to $(BOARD_DIR)/include" $(Q) $(DIRLINK) $(BOARD_DIR)/include include/arch/board # Link the configs//src dir to arch//src/board -$(ARCH_SRC)/board: +$(ARCH_SRC)/board: Make.defs @echo "LN: $(ARCH_SRC)/board to $(BOARD_DIR)/src" $(Q) $(DIRLINK) $(BOARD_DIR)/src $(ARCH_SRC)/board # Link arch//include/ to arch//include/chip -$(ARCH_SRC)/chip: +$(ARCH_SRC)/chip: Make.defs ifneq ($(CONFIG_ARCH_CHIP),) @echo "LN: $(ARCH_SRC)/chip to $(ARCH_SRC)/$(CONFIG_ARCH_CHIP)" $(Q) $(DIRLINK) $(TOPDIR)/$(ARCH_SRC)/$(CONFIG_ARCH_CHIP) $(ARCH_SRC)/chip @@ -321,7 +319,7 @@ endif # Link arch//src/ to arch//src/chip -include/arch/chip: include/arch +include/arch/chip: include/arch Make.defs ifneq ($(CONFIG_ARCH_CHIP),) @echo "LN: include/arch/chip to $(ARCH_INC)/$(CONFIG_ARCH_CHIP)" $(Q) $(DIRLINK) $(TOPDIR)/$(ARCH_INC)/$(CONFIG_ARCH_CHIP) include/arch/chip diff --git a/Makefile.win b/Makefile.win index e904c26ae5..a449cd346d 100644 --- a/Makefile.win +++ b/Makefile.win @@ -281,16 +281,9 @@ Make.defs: $(Q) echo "include $(TOPDIR)$(DELIM).config" > Make.defs $(Q) echo "include $(TOPDIR)$(DELIM)tools$(DELIM)Config.mk" >> Make.defs -tools\initialconfig$(HOSTEXEEXT): - $(Q) $(MAKE) -C tools -f Makefile.host TOPDIR="$(TOPDIR)" initialconfig$(HOSTEXEEXT) - -.config: tools\initialconfig$(HOSTEXEEXT) - $(Q) echo "No .config file found, creating one" - $(Q) tools\initialconfig$(HOSTEXEEXT) - # Link the arch\\include directory to include\arch -include\arch: .config Make.defs +include\arch: Make.defs @echo LN: include\arch to $(ARCH_DIR)\include ifeq ($(CONFIG_WINDOWS_MKLINK),y) $(Q) /user:administrator mklink /d include\arch $(TOPDIR)\$(ARCH_DIR)\include @@ -301,7 +294,7 @@ endif # Link the configs\\include directory to include\arch\board -include\arch\board: include\arch +include\arch\board: include\arch Make.defs include\arch @echo LN: include\arch\board to $(BOARD_DIR)\include ifeq ($(CONFIG_WINDOWS_MKLINK),y) $(Q) /user:administrator mklink /d include\arch\board $(BOARD_DIR)\include @@ -312,7 +305,7 @@ endif # Link the configs\\src dir to arch\\src\board -$(ARCH_SRC)\board: +$(ARCH_SRC)\board: Make.defs @echo LN: $(ARCH_SRC)\board to $(BOARD_DIR)\src ifeq ($(CONFIG_WINDOWS_MKLINK),y) $(Q) /user:administrator mklink /d $(ARCH_SRC)\board $(BOARD_DIR)\src @@ -323,7 +316,7 @@ endif # Link arch\\include\ to arch\\include\chip -$(ARCH_SRC)\chip: +$(ARCH_SRC)\chip: Make.defs ifneq ($(CONFIG_ARCH_CHIP),) @echo LN: $(ARCH_SRC)\chip to $(ARCH_SRC)\$(CONFIG_ARCH_CHIP) ifeq ($(CONFIG_WINDOWS_MKLINK),y) @@ -336,7 +329,7 @@ endif # Link arch\\src\ to arch\\src\chip -include\arch\chip: include\arch +include\arch\chip: include\arch Make.defs ifneq ($(CONFIG_ARCH_CHIP),) @echo LN: include\arch\chip to $(ARCH_INC)\$(CONFIG_ARCH_CHIP) ifeq ($(CONFIG_WINDOWS_MKLINK),y) diff --git a/tools/initialconfig.c b/tools/initialconfig.c index 40b98b460d..90246dbe63 100644 --- a/tools/initialconfig.c +++ b/tools/initialconfig.c @@ -841,10 +841,5 @@ int main(int argc, char **argv) */ create_config(); - - /* TODO: Copy a Make.defs file from a configuration for the selected - * board that supports the selected MCU. - */ - return 0; }