Allows for BaseTools-specific tweaks in include files.

Signed-off-by: Gerd Hoffmann <kra...@redhat.com>
---
 BaseTools/Source/C/Makefiles/header.makefile | 3 +++
 BaseTools/Source/C/Makefiles/ms.common       | 4 ++--
 2 files changed, 5 insertions(+), 2 deletions(-)

diff --git a/BaseTools/Source/C/Makefiles/header.makefile 
b/BaseTools/Source/C/Makefiles/header.makefile
index 1bf003523baf..6b743fa297b0 100644
--- a/BaseTools/Source/C/Makefiles/header.makefile
+++ b/BaseTools/Source/C/Makefiles/header.makefile
@@ -124,6 +124,9 @@ ifeq ($(DARWIN),Darwin)
 endif
 endif
 
+CFLAGS   += -D BASETOOLS=1
+CXXFLAGS += -D BASETOOLS=1
+
 # keep BUILD_OPTFLAGS last
 CFLAGS   += $(BUILD_OPTFLAGS)
 CXXFLAGS += $(BUILD_OPTFLAGS)
diff --git a/BaseTools/Source/C/Makefiles/ms.common 
b/BaseTools/Source/C/Makefiles/ms.common
index 8391f10d5dd2..6fc4c6477847 100644
--- a/BaseTools/Source/C/Makefiles/ms.common
+++ b/BaseTools/Source/C/Makefiles/ms.common
@@ -57,5 +57,5 @@ LINKER = $(LD)
 
 INC = $(INC) -I . -I $(SOURCE_PATH)\Include -I $(ARCH_INCLUDE) -I 
$(SOURCE_PATH)\Common
 
-CFLAGS = $(CFLAGS) /nologo /Z7 /c /O2 /MT /W4 /WX /D _CRT_SECURE_NO_DEPRECATE 
/D _CRT_NONSTDC_NO_DEPRECATE
-CPPFLAGS = $(CPPFLAGS) /EHsc /nologo /Z7 /c /O2 /MT /D 
_CRT_SECURE_NO_DEPRECATE /D _CRT_NONSTDC_NO_DEPRECATE
+CFLAGS = $(CFLAGS) /nologo /Z7 /c /O2 /MT /W4 /WX /D _CRT_SECURE_NO_DEPRECATE 
/D _CRT_NONSTDC_NO_DEPRECATE /D BASETOOLS
+CPPFLAGS = $(CPPFLAGS) /EHsc /nologo /Z7 /c /O2 /MT /D 
_CRT_SECURE_NO_DEPRECATE /D _CRT_NONSTDC_NO_DEPRECATE /D BASETOOLS
-- 
2.39.2



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#102932): https://edk2.groups.io/g/devel/message/102932
Mute This Topic: https://groups.io/mt/98236904/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


Reply via email to