tools/Config.mk: add DEFINE macro like INCDIR

This commit is contained in:
Xiang Xiao 2018-05-13 17:22:25 +08:00 committed by Gregory Nutt
parent 2483b65bfb
commit adbff7de81
6 changed files with 7 additions and 17 deletions

View File

@ -38,11 +38,7 @@
# CFLAGS
ifneq ($(CONFIG_BUILD_FLAT),y)
ifeq ($(CONFIG_WINDOWS_NATIVE),y)
KDEFINE = ${shell $(TOPDIR)\tools\define.bat "$(CC)" __KERNEL__}
else
KDEFINE = ${shell $(TOPDIR)/tools/define.sh "$(CC)" __KERNEL__}
endif
KDEFINE = ${shell $(DEFINE) "$(CC)" __KERNEL__}
endif
# Sources and paths

View File

@ -38,11 +38,7 @@
# CFLAGS
ifneq ($(CONFIG_BUILD_FLAT),y)
ifeq ($(CONFIG_WINDOWS_NATIVE),y)
KDEFINE = ${shell $(TOPDIR)\tools\define.bat "$(CC)" __KERNEL__}
else
KDEFINE = ${shell $(TOPDIR)/tools/define.sh "$(CC)" __KERNEL__}
endif
KDEFINE = ${shell $(DEFINE) "$(CC)" __KERNEL__}
endif
# Sources and paths

View File

@ -41,11 +41,7 @@ DELIM := $(strip /)
# CFLAGS
ifneq ($(CONFIG_BUILD_FLAT),y)
ifeq ($(CONFIG_WINDOWS_NATIVE),y)
KDEFINE = ${shell $(TOPDIR)\tools\define.bat "$(CC)" __KERNEL__}
else
KDEFINE = ${shell $(TOPDIR)/tools/define.sh "$(CC)" __KERNEL__}
endif
KDEFINE = ${shell $(DEFINE) "$(CC)" __KERNEL__}
endif
# Sources and paths

View File

@ -93,8 +93,10 @@ endif
# CONFIG_WINDOWS_NATIVE - Defined for a Windows native build
ifeq ($(CONFIG_WINDOWS_NATIVE),y)
DEFINE = "$(TOPDIR)\tools\define.bat"
INCDIR = "$(TOPDIR)\tools\incdir.bat"
else
DEFINE = "$(TOPDIR)/tools/define.sh"
INCDIR = "$(TOPDIR)/tools/incdir.sh"
endif

View File

@ -81,7 +81,7 @@ endif
# This define is passed as EXTRADEFINES for kernel-mode builds. It is also passed
# during PASS1 (but not PASS2) context and depend targets.
KDEFINE = ${shell $(TOPDIR)/tools/define.sh "$(CC)" __KERNEL__}
KDEFINE = ${shell $(DEFINE) "$(CC)" __KERNEL__}
# Process architecture and board-specific directories

View File

@ -66,7 +66,7 @@ endif
# This define is passed as EXTRADEFINES for kernel-mode builds. It is also passed
# during PASS1 (but not PASS2) context and depend targets.
KDEFINE = ${shell $(TOPDIR)\tools\define.bat "$(CC)" __KERNEL__}
KDEFINE = ${shell $(DEFINE) "$(CC)" __KERNEL__}
# Process architecture and board-specific directories