From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail.byosoft.com.cn (mail.byosoft.com.cn [58.240.74.242]) by mx.groups.io with SMTP id smtpd.web12.12309.1600218172915842481 for ; Tue, 15 Sep 2020 18:02:53 -0700 Authentication-Results: mx.groups.io; dkim=missing; spf=none, err=permanent DNS error (domain: byosoft.com.cn, ip: 58.240.74.242, mailfrom: gaoliming@byosoft.com.cn) Received: from localhost.localdomain ([58.246.60.130]) (envelope-sender ) by 192.168.6.13 with ESMTP for ; Wed, 16 Sep 2020 09:02:51 +0800 X-WM-Sender: gaoliming@byosoft.com.cn X-WM-AuthFlag: YES X-WM-AuthUser: gaoliming@byosoft.com.cn From: "gaoliming" To: devel@edk2.groups.io Cc: Bob Feng , Yuwei Chen Subject: [PATCH 1/1] BaseTools: Copy PACKED definition from MdePkg Base.h Date: Wed, 16 Sep 2020 09:02:38 +0800 Message-Id: <20200916010238.2031-1-gaoliming@byosoft.com.cn> X-Mailer: git-send-email 2.27.0.windows.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=2938 MdePkg Acpi10.h definition depends on PACKED. When structure PCD refers to Acpi10.h, build will fail, because PACKED definition is missing in BaseTools BaseTypes.h. Cc: Bob Feng Cc: Yuwei Chen Signed-off-by: Liming Gao --- BaseTools/Source/C/Include/Common/BaseTypes.h | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/BaseTools/Source/C/Include/Common/BaseTypes.h b/BaseTools/Source/C/Include/Common/BaseTypes.h index 31d0662085a8..150980b4c0bf 100644 --- a/BaseTools/Source/C/Include/Common/BaseTypes.h +++ b/BaseTools/Source/C/Include/Common/BaseTypes.h @@ -57,6 +57,16 @@ #define NULL ((VOID *) 0) #endif +#ifdef __CC_ARM + // + // Older RVCT ARM compilers don't fully support #pragma pack and require __packed + // as a prefix for the structure. + // + #define PACKED __packed +#else + #define PACKED +#endif + // // Support for variable length argument lists using the ANSI standard. // -- 2.27.0.windows.1