blob: 783b7644392e638bc5383ee2a7f2531447f2e3ec [file] [log] [blame]
Patrick Williams8dd68482022-10-04 07:57:18 -05001From 17f490101f51b03c1ffc7151cc35e9fbd42b6060 Mon Sep 17 00:00:00 2001
2From: Ross Burton <ross.burton@arm.com>
3Date: Tue, 22 Feb 2022 10:38:13 +0000
4Subject: [PATCH] Latest clang is causing build failures because -Werror is
5 used
Brad Bishopbec4ebc2022-08-03 09:55:16 -04006
7 edk2/MdeModulePkg/Include/Guid/ExtendedFirmwarePerformance.h:78:47:
8 error: field Guid within 'FPDT_GUID_EVENT_RECORD' is less aligned than 'EFI_GUID'
9 and is usually due to 'FPDT_GUID_EVENT_RECORD' being packed, which can lead to
10 unaligned accesses [-Werror,-Wunaligned-access]
11
12This has been reported upstream[1] so until this is resolved, ignore the warnings.
13
14[1] https://edk2.groups.io/g/devel/message/86838
15
16Upstream-Status: Pending
17Signed-off-by: Ross Burton <ross.burton@arm.com>
Patrick Williams8dd68482022-10-04 07:57:18 -050018---
19 BaseTools/Conf/tools_def.template | 2 +-
20 1 file changed, 1 insertion(+), 1 deletion(-)
Brad Bishopbec4ebc2022-08-03 09:55:16 -040021
22diff --git a/BaseTools/Conf/tools_def.template b/BaseTools/Conf/tools_def.template
Patrick Williams8dd68482022-10-04 07:57:18 -050023index 5ed19810b7..9b4f173519 100755
Brad Bishopbec4ebc2022-08-03 09:55:16 -040024--- a/BaseTools/Conf/tools_def.template
25+++ b/BaseTools/Conf/tools_def.template
Patrick Williams8dd68482022-10-04 07:57:18 -050026@@ -2548,7 +2548,7 @@ DEFINE CLANG38_X64_PREFIX = ENV(CLANG38_BIN)
27 DEFINE CLANG38_IA32_TARGET = -target i686-pc-linux-gnu
28 DEFINE CLANG38_X64_TARGET = -target x86_64-pc-linux-gnu
29
Brad Bishopbec4ebc2022-08-03 09:55:16 -040030-DEFINE CLANG38_WARNING_OVERRIDES = -Wno-parentheses-equality -Wno-tautological-compare -Wno-tautological-constant-out-of-range-compare -Wno-empty-body -Wno-unused-const-variable -Wno-varargs -Wno-unknown-warning-option -Wno-unused-but-set-variable -Wno-unused-const-variable
Patrick Williams8dd68482022-10-04 07:57:18 -050031+DEFINE CLANG38_WARNING_OVERRIDES = -Wno-parentheses-equality -Wno-tautological-compare -Wno-tautological-constant-out-of-range-compare -Wno-empty-body -Wno-unused-const-variable -Wno-varargs -Wno-unknown-warning-option -Wno-unused-but-set-variable -Wno-unused-const-variable -Wno-error=unaligned-access -Wno-unused-command-line-argument
32 DEFINE CLANG38_ALL_CC_FLAGS = DEF(GCC48_ALL_CC_FLAGS) DEF(CLANG38_WARNING_OVERRIDES) -fno-stack-protector -mms-bitfields -Wno-address -Wno-shift-negative-value -Wno-unknown-pragmas -Wno-incompatible-library-redeclaration -fno-asynchronous-unwind-tables -mno-sse -mno-mmx -msoft-float -mno-implicit-float -ftrap-function=undefined_behavior_has_been_optimized_away_by_clang -funsigned-char -fno-ms-extensions -Wno-null-dereference
33
34 ###########################