From 4595f9388fb5bf3c6028a3f88298c6840146f219 Mon Sep 17 00:00:00 2001 From: xuxin19 Date: Thu, 4 Jan 2024 16:58:49 +0800 Subject: [PATCH] tools/Unix.mk:make incdir precedence over other targets Make.defs need incdir at the very beginning. fix error such as `make menuconfig` `make oldconfig` etc. Signed-off-by: xuxin19 --- tools/Unix.mk | 4 ++-- tools/Win.mk | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/tools/Unix.mk b/tools/Unix.mk index 3b55b3d91e..36f8f073fc 100644 --- a/tools/Unix.mk +++ b/tools/Unix.mk @@ -416,7 +416,7 @@ DIRLINKS_FILE += $(DIRLINKS_EXTERNAL_DEP) # The symlink subfolders need to be removed before the parent symlinks .PHONY: clean_dirlinks -clean_dirlinks: +clean_dirlinks: tools/incdir$(HOSTEXEEXT) $(Q) $(call DELFILE, $(DIRLINKS_FILE)) $(Q) $(call DELFILE, .dirlinks) $(Q) $(DIRUNLINK) drivers/platform @@ -815,7 +815,7 @@ endif # apps_distclean: Perform the distclean operation only in the user application # directory. -apps_preconfig: .dirlinks +apps_preconfig: tools/incdir$(HOSTEXEEXT) .dirlinks ifneq ($(APPDIR),) $(Q) $(MAKE) -C $(APPDIR) preconfig endif diff --git a/tools/Win.mk b/tools/Win.mk index 87fb218261..0f3273e2ec 100644 --- a/tools/Win.mk +++ b/tools/Win.mk @@ -397,7 +397,7 @@ DIRLINKS_FILE += $(DIRLINKS_EXTERNAL_DEP) # The symlink subfolders need to be removed before the parent symlinks .PHONY: clean_dirlinks -clean_dirlinks: +clean_dirlinks: tools\incdir$(HOSTEXEEXT) $(Q) $(call DELFILE, $(DIRLINKS_FILE)) $(Q) $(call DELFILE, .dirlinks) $(Q) $(DIRUNLINK) drivers\platform @@ -731,7 +731,7 @@ endif # apps_distclean: Perform the distclean operation only in the user application # directory. -apps_preconfig: .dirlinks +apps_preconfig: tools\incdir$(HOSTEXEEXT) .dirlinks ifneq ($(APPDIR),) $(Q) $(MAKE) -C "$(APPDIR)" preconfig endif