From b65afdde74d6c1fac1cdbd2efdad23ba26295808 Mon Sep 17 00:00:00 2001 From: fengyunhua Date: Sun, 11 Oct 2020 06:24:54 +0800 Subject: [PATCH] BaseTools: Add EDKII_DSC_PLATFORM_GUID MACRO REF: https://bugzilla.tianocore.org/show_bug.cgi?id=2969 Add EDKII_DSC_PLATFORM_GUID MACRO to AutoGen.h and AutoGen.c Cc: Bob Feng Cc: Liming Gao Signed-off-by: Yunhua Feng Reviewed-by: Bob Feng Tested-by: Michael Kubacki Reviewed-by: Liming Gao --- BaseTools/Source/Python/AutoGen/GenC.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/BaseTools/Source/Python/AutoGen/GenC.py b/BaseTools/Source/Python/AutoGen/GenC.py index 5e0d11e165..a2053d5485 100755 --- a/BaseTools/Source/Python/AutoGen/GenC.py +++ b/BaseTools/Source/Python/AutoGen/GenC.py @@ -1980,12 +1980,14 @@ def CreateHeaderCode(Info, AutoGenC, AutoGenH): AutoGenH.Append("#include \n") AutoGenH.Append('\nextern GUID gEfiCallerIdGuid;') + AutoGenH.Append('\nextern GUID gEdkiiDscPlatformGuid;') AutoGenH.Append('\nextern CHAR8 *gEfiCallerBaseName;\n\n') if Info.IsLibrary: return AutoGenH.Append("#define EFI_CALLER_ID_GUID \\\n %s\n" % GuidStringToGuidStructureString(Info.Guid)) + AutoGenH.Append("#define EDKII_DSC_PLATFORM_GUID \\\n %s\n" % GuidStringToGuidStructureString(Info.PlatformInfo.Guid)) if Info.IsLibrary: return @@ -2002,6 +2004,7 @@ def CreateHeaderCode(Info, AutoGenC, AutoGenH): # Publish the CallerId Guid # AutoGenC.Append('\nGLOBAL_REMOVE_IF_UNREFERENCED GUID gEfiCallerIdGuid = %s;\n' % GuidStringToGuidStructureString(Info.Guid)) + AutoGenC.Append('\nGLOBAL_REMOVE_IF_UNREFERENCED GUID gEdkiiDscPlatformGuid = %s;\n' % GuidStringToGuidStructureString(Info.PlatformInfo.Guid)) AutoGenC.Append('\nGLOBAL_REMOVE_IF_UNREFERENCED CHAR8 *gEfiCallerBaseName = "%s";\n' % Info.Name) ## Create common code for header file