From: "Guo, Gua" <gua.guo@intel.com>
To: "devel@edk2.groups.io" <devel@edk2.groups.io>,
"Guo, Gua" <gua.guo@intel.com>,
"rebecca@bsdio.com" <rebecca@bsdio.com>,
"Oliver Smith-Denny" <osd@smith-denny.com>,
"Jiang, Guomin" <guomin.jiang@intel.com>,
"Lu, Xiaoyu1" <xiaoyu1.lu@intel.com>,
"Wang, Jian J" <jian.j.wang@intel.com>,
"Yao, Jiewen" <jiewen.yao@intel.com>,
Ard Biesheuvel <ardb+tianocore@kernel.org>,
"Justen, Jordan L" <jordan.l.justen@intel.com>,
Gerd Hoffmann <kraxel@redhat.com>,
"Feng, Bob C" <bob.c.feng@intel.com>,
"Gao, Liming" <gaoliming@byosoft.com.cn>,
Andrew Fish <afish@apple.com>,
"Leif Lindholm" <quic_llindhol@quicinc.com>,
"Kinney, Michael D" <michael.d.kinney@intel.com>
Subject: Re: [edk2-devel] [PATCH v2 03/13] BaseTools: Update CLANGDWARF toolchain and remove CLANG35 and CLANG38
Date: Wed, 29 Mar 2023 09:24:45 +0000 [thread overview]
Message-ID: <BL1PR11MB5478D93852428AF6EA0A3FD9EF899@BL1PR11MB5478.namprd11.prod.outlook.com> (raw)
In-Reply-To: <1750C725F99FA0C2.29160@groups.io>
[-- Attachment #1.1: Type: text/plain, Size: 40828 bytes --]
And I also try to pick the patch to my local.
Look like the patch encounter the failure.
Have any verify step on your side, maybe we can align it.
edksetup Rebuild.bat
py -3 UefiPayloadPkg\UniversalPayloadBuild.py -t CLANGDWARF
Thanks,
Gua Guo
From: devel@edk2.groups.io <devel@edk2.groups.io> On Behalf Of Guo, Gua
Sent: Wednesday, March 29, 2023 11:47 AM
To: devel@edk2.groups.io; rebecca@bsdio.com; Oliver Smith-Denny <osd@smith-denny.com>; Jiang, Guomin <guomin.jiang@intel.com>; Lu, Xiaoyu1 <xiaoyu1.lu@intel.com>; Wang, Jian J <jian.j.wang@intel.com>; Yao, Jiewen <jiewen.yao@intel.com>; Ard Biesheuvel <ardb+tianocore@kernel.org>; Justen, Jordan L <jordan.l.justen@intel.com>; Gerd Hoffmann <kraxel@redhat.com>; Feng, Bob C <bob.c.feng@intel.com>; Gao, Liming <gaoliming@byosoft.com.cn>; Andrew Fish <afish@apple.com>; Leif Lindholm <quic_llindhol@quicinc.com>; Kinney, Michael D <michael.d.kinney@intel.com>
Subject: Re: [edk2-devel] [PATCH v2 03/13] BaseTools: Update CLANGDWARF toolchain and remove CLANG35 and CLANG38
@rebecca@bsdio.com<mailto:rebecca@bsdio.com>
On this part, whether is better to change it from "objcopy" to "llvm-objcopy"
Windows path: C:\Program Files (x86)\llvm-objcopy.exe
Linux path: /usr/bin/llvm-objcopy
[cid:image001.png@01D96263.52CA3C10]
Thanks,
Gua
-----Original Message-----
From: devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>> On Behalf Of Rebecca Cran
Sent: Wednesday, March 29, 2023 1:31 AM
To: devel@edk2.groups.io<mailto:devel@edk2.groups.io>; Oliver Smith-Denny <osd@smith-denny.com<mailto:osd@smith-denny.com>>; Jiang, Guomin <guomin.jiang@intel.com<mailto:guomin.jiang@intel.com>>; Lu, Xiaoyu1 <xiaoyu1.lu@intel.com<mailto:xiaoyu1.lu@intel.com>>; Wang, Jian J <jian.j.wang@intel.com<mailto:jian.j.wang@intel.com>>; Yao, Jiewen <jiewen.yao@intel.com<mailto:jiewen.yao@intel.com>>; Ard Biesheuvel <ardb+tianocore@kernel.org<mailto:ardb+tianocore@kernel.org>>; Justen, Jordan L <jordan.l.justen@intel.com<mailto:jordan.l.justen@intel.com>>; Gerd Hoffmann <kraxel@redhat.com<mailto:kraxel@redhat.com>>; Feng, Bob C <bob.c.feng@intel.com<mailto:bob.c.feng@intel.com>>; Gao, Liming <gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>>; Andrew Fish <afish@apple.com<mailto:afish@apple.com>>; Leif Lindholm <quic_llindhol@quicinc.com<mailto:quic_llindhol@quicinc.com>>; Kinney, Michael D <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>
Cc: Rebecca Cran <rebecca@bsdio.com<mailto:rebecca@bsdio.com>>
Subject: [edk2-devel] [PATCH v2 03/13] BaseTools: Update CLANGDWARF toolchain and remove CLANG35 and CLANG38
Update the CLANGDWARF toolchain definition with the settings from CLANG38, and delete the CLANG35 and CLANG38 toolchains.
The CLANG35 and CLANG38 toolchains were added for compatibility with ARM's proprietary clang-based toolchain. Things have since moved on, and with the latest clang version being 16.0.0, versions 3.5 and 3.9 are obsolete and can be removed.
Signed-off-by: Rebecca Cran <rebecca@bsdio.com<mailto:rebecca@bsdio.com>>
---
BaseTools/Conf/tools_def.template | 453 ++++++++------------
1 file changed, 171 insertions(+), 282 deletions(-)
diff --git a/BaseTools/Conf/tools_def.template b/BaseTools/Conf/tools_def.template
index 2f0b804acef3..3abd22615533 100755
--- a/BaseTools/Conf/tools_def.template
+++ b/BaseTools/Conf/tools_def.template
@@ -273,32 +273,21 @@ DEFINE DTC_BIN = ENV(DTC_PREFIX)dtc
# Required to build platforms or ACPI tables:
# Intel(r) ACPI Compiler from
# https://acpica.org/downloads
-#
-# CLANG35 -Linux,Windows- Requires:
-# Clang v3.5 or later, and GNU binutils targeting aarch64-linux-gnu or arm-linux-gnueabi
-# Optional:
-# Required to build platforms or ACPI tables:
-# Intel(r) ACPI Compiler from
-# https://acpica.org/downloads
-# CLANG38 -Linux- Requires:
-# Clang v3.8, LLVMgold plugin and GNU binutils 2.26 targeting x86_64-linux-gnu, aarch64-linux-gnu or arm-linux-gnueabi
-# Clang v3.9 or later, LLVMgold plugin and GNU binutils 2.28 targeting x86_64-linux-gnu, aarch64-linux-gnu or arm-linux-gnueabi
+# CLANGDWARF -Linux- Requires:
+# Clang 9 or above, and GNU binutils targeting x86_64-linux-gnu, aaarch64-linux-gnu or arm-linux-gnuaebi
# Optional:
# Required to build platforms or ACPI tables:
# Intel(r) ACPI Compiler from
# https://acpica.org/downloads
+# Required to compile nasm source:
+# nasm compiler from
+# NASM -- https://nasm.us
# CLANGPDB -Linux, Windows, Mac- Requires:
# Clang 9 or above from http://releases.llvm.org/
# Optional:
# Required to compile nasm source:
# nasm compiler from
# NASM -- http://www.nasm.us/
-# CLANGDWARF -Linux, Windows, Mac- Requires:
-# Clang 9 or above from http://releases.llvm.org/
-# Optional:
-# Required to compile nasm source:
-# nasm compiler from
-# NASM -- http://www.nasm.us/
# VS2008x86 -win64- Requires:
# Microsoft Visual Studio 2008 (x86)
# Microsoft Windows Server 2003 Driver Development Kit (Microsoft WINDDK) version 3790.1830
@@ -2483,187 +2472,187 @@ RELEASE_GCC5_LOONGARCH64_CC_FLAGS = DEF(GCC5_LOONGARCH64_CC_FLAGS) -Wno-un
# PE/COFF binaries using LLVM/Clang with Link Time Optimization enabled # ####################################################################################
-*_CLANG38_*_*_FAMILY = GCC
-*_CLANG38_*_MAKE_PATH = make
-*_CLANG38_*_*_DLL = ENV(CLANG38_DLL)
-*_CLANG38_*_ASL_PATH = DEF(UNIX_IASL_BIN)
+*_CLANGDWARF_*_*_FAMILY = GCC
+*_CLANGDWARF_*_MAKE_PATH = make
+*_CLANGDWARF_*_*_DLL = ENV(CLANGDWARF_DLL)
+*_CLANGDWARF_*_ASL_PATH = DEF(UNIX_IASL_BIN)
-*_CLANG38_*_APP_FLAGS =
-*_CLANG38_*_ASL_FLAGS = DEF(IASL_FLAGS)
-*_CLANG38_*_ASL_OUTFLAGS = DEF(IASL_OUTFLAGS)
-*_CLANG38_*_DEPS_FLAGS = DEF(GCC_DEPS_FLAGS)
-DEFINE CLANG38_IA32_PREFIX = ENV(CLANG38_BIN)
-DEFINE CLANG38_X64_PREFIX = ENV(CLANG38_BIN)
+*_CLANGDWARF_*_APP_FLAGS =
+*_CLANGDWARF_*_ASL_FLAGS = DEF(IASL_FLAGS)
+*_CLANGDWARF_*_ASL_OUTFLAGS = DEF(IASL_OUTFLAGS)
+*_CLANGDWARF_*_DEPS_FLAGS = DEF(GCC_DEPS_FLAGS)
+DEFINE CLANGDWARF_IA32_PREFIX = ENV(CLANGDWARF_BIN)
+DEFINE CLANGDWARF_X64_PREFIX = ENV(CLANGDWARF_BIN)
-DEFINE CLANG38_IA32_TARGET = -target i686-pc-linux-gnu
-DEFINE CLANG38_X64_TARGET = -target x86_64-pc-linux-gnu
+DEFINE CLANGDWARF_IA32_TARGET = -target i686-pc-linux-gnu
+DEFINE CLANGDWARF_X64_TARGET = -target x86_64-pc-linux-gnu
-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-unaligned-access
-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
+DEFINE CLANGDWARF_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-unaligned-access
+DEFINE CLANGDWARF_ALL_CC_FLAGS = DEF(GCC48_ALL_CC_FLAGS) DEF(CLANGDWARF_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
###########################
-# CLANG38 IA32 definitions
+# CLANGDWARF IA32 definitions
###########################
-*_CLANG38_IA32_OBJCOPY_PATH = objcopy
-*_CLANG38_IA32_CC_PATH = DEF(CLANG38_IA32_PREFIX)clang
-*_CLANG38_IA32_SLINK_PATH = DEF(CLANG38_IA32_PREFIX)llvm-ar
-*_CLANG38_IA32_DLINK_PATH = DEF(CLANG38_IA32_PREFIX)clang
-*_CLANG38_IA32_ASLDLINK_PATH = DEF(CLANG38_IA32_PREFIX)clang
-*_CLANG38_IA32_ASM_PATH = DEF(CLANG38_IA32_PREFIX)clang
-*_CLANG38_IA32_PP_PATH = DEF(CLANG38_IA32_PREFIX)clang
-*_CLANG38_IA32_VFRPP_PATH = DEF(CLANG38_IA32_PREFIX)clang
-*_CLANG38_IA32_ASLCC_PATH = DEF(CLANG38_IA32_PREFIX)clang
-*_CLANG38_IA32_ASLPP_PATH = DEF(CLANG38_IA32_PREFIX)clang
-*_CLANG38_IA32_RC_PATH = objcopy
-
-*_CLANG38_IA32_ASLCC_FLAGS = DEF(GCC_ASLCC_FLAGS) -m32 -fno-lto DEF(CLANG38_IA32_TARGET)
-*_CLANG38_IA32_ASLDLINK_FLAGS = DEF(GCC5_IA32_X64_ASLDLINK_FLAGS) -Wl,-m,elf_i386
-*_CLANG38_IA32_ASM_FLAGS = DEF(GCC5_ASM_FLAGS) -m32 -march=i386 DEF(CLANG38_IA32_TARGET)
-*_CLANG38_IA32_RC_FLAGS = DEF(GCC_IA32_RC_FLAGS)
-*_CLANG38_IA32_OBJCOPY_FLAGS =
-*_CLANG38_IA32_NASM_FLAGS = -f elf32
-*_CLANG38_IA32_PP_FLAGS = DEF(GCC_PP_FLAGS) DEF(CLANG38_IA32_TARGET)
-*_CLANG38_IA32_ASLPP_FLAGS = DEF(GCC_ASLPP_FLAGS) DEF(CLANG38_IA32_TARGET)
-*_CLANG38_IA32_VFRPP_FLAGS = DEF(GCC_VFRPP_FLAGS) DEF(CLANG38_IA32_TARGET)
-
-DEBUG_CLANG38_IA32_CC_FLAGS = DEF(CLANG38_ALL_CC_FLAGS) -m32 -Oz -flto -march=i586 DEF(CLANG38_IA32_TARGET) -g -malign-double
-DEBUG_CLANG38_IA32_DLINK_FLAGS = DEF(GCC5_IA32_X64_DLINK_FLAGS) -flto -Wl,-Oz -Wl,-melf_i386 -Wl,--oformat=elf32-i386
-DEBUG_CLANG38_IA32_DLINK2_FLAGS = DEF(GCC5_IA32_DLINK2_FLAGS) -O3
-
-RELEASE_CLANG38_IA32_CC_FLAGS = DEF(CLANG38_ALL_CC_FLAGS) -m32 -Oz -flto -march=i586 DEF(CLANG38_IA32_TARGET) -malign-double
-RELEASE_CLANG38_IA32_DLINK_FLAGS = DEF(GCC5_IA32_X64_DLINK_FLAGS) -flto -Wl,-Oz -Wl,-melf_i386 -Wl,--oformat=elf32-i386
-RELEASE_CLANG38_IA32_DLINK2_FLAGS = DEF(GCC5_IA32_DLINK2_FLAGS) -O3
-
-NOOPT_CLANG38_IA32_CC_FLAGS = DEF(CLANG38_ALL_CC_FLAGS) -m32 -O0 -march=i586 DEF(CLANG38_IA32_TARGET) -g -malign-double
-NOOPT_CLANG38_IA32_DLINK_FLAGS = DEF(GCC5_IA32_X64_DLINK_FLAGS) -Wl,-O0 -Wl,-melf_i386 -Wl,--oformat=elf32-i386
-NOOPT_CLANG38_IA32_DLINK2_FLAGS = DEF(GCC5_IA32_DLINK2_FLAGS) -O0
+*_CLANGDWARF_IA32_OBJCOPY_PATH = objcopy
+*_CLANGDWARF_IA32_CC_PATH = DEF(CLANGDWARF_IA32_PREFIX)clang
+*_CLANGDWARF_IA32_SLINK_PATH = DEF(CLANGDWARF_IA32_PREFIX)llvm-ar
+*_CLANGDWARF_IA32_DLINK_PATH = DEF(CLANGDWARF_IA32_PREFIX)clang
+*_CLANGDWARF_IA32_ASLDLINK_PATH = DEF(CLANGDWARF_IA32_PREFIX)clang
+*_CLANGDWARF_IA32_ASM_PATH = DEF(CLANGDWARF_IA32_PREFIX)clang
+*_CLANGDWARF_IA32_PP_PATH = DEF(CLANGDWARF_IA32_PREFIX)clang
+*_CLANGDWARF_IA32_VFRPP_PATH = DEF(CLANGDWARF_IA32_PREFIX)clang
+*_CLANGDWARF_IA32_ASLCC_PATH = DEF(CLANGDWARF_IA32_PREFIX)clang
+*_CLANGDWARF_IA32_ASLPP_PATH = DEF(CLANGDWARF_IA32_PREFIX)clang
+*_CLANGDWARF_IA32_RC_PATH = objcopy
+
+*_CLANGDWARF_IA32_ASLCC_FLAGS = DEF(GCC_ASLCC_FLAGS) -m32 -fno-lto DEF(CLANGDWARF_IA32_TARGET)
+*_CLANGDWARF_IA32_ASLDLINK_FLAGS = DEF(GCC5_IA32_X64_ASLDLINK_FLAGS) -Wl,-m,elf_i386
+*_CLANGDWARF_IA32_ASM_FLAGS = DEF(GCC5_ASM_FLAGS) -m32 -march=i386 DEF(CLANGDWARF_IA32_TARGET)
+*_CLANGDWARF_IA32_RC_FLAGS = DEF(GCC_IA32_RC_FLAGS)
+*_CLANGDWARF_IA32_OBJCOPY_FLAGS =
+*_CLANGDWARF_IA32_NASM_FLAGS = -f elf32
+*_CLANGDWARF_IA32_PP_FLAGS = DEF(GCC_PP_FLAGS) DEF(CLANGDWARF_IA32_TARGET)
+*_CLANGDWARF_IA32_ASLPP_FLAGS = DEF(GCC_ASLPP_FLAGS) DEF(CLANGDWARF_IA32_TARGET)
+*_CLANGDWARF_IA32_VFRPP_FLAGS = DEF(GCC_VFRPP_FLAGS) DEF(CLANGDWARF_IA32_TARGET)
+
+DEBUG_CLANGDWARF_IA32_CC_FLAGS = DEF(CLANGDWARF_ALL_CC_FLAGS) -m32 -Oz -flto -march=i586 DEF(CLANGDWARF_IA32_TARGET) -g -malign-double
+DEBUG_CLANGDWARF_IA32_DLINK_FLAGS = DEF(GCC5_IA32_X64_DLINK_FLAGS) -flto -Wl,-Oz -Wl,-melf_i386 -Wl,--oformat=elf32-i386
+DEBUG_CLANGDWARF_IA32_DLINK2_FLAGS = DEF(GCC5_IA32_DLINK2_FLAGS) -O3
+
+RELEASE_CLANGDWARF_IA32_CC_FLAGS = DEF(CLANGDWARF_ALL_CC_FLAGS) -m32 -Oz -flto -march=i586 DEF(CLANGDWARF_IA32_TARGET) -malign-double
+RELEASE_CLANGDWARF_IA32_DLINK_FLAGS = DEF(GCC5_IA32_X64_DLINK_FLAGS) -flto -Wl,-Oz -Wl,-melf_i386 -Wl,--oformat=elf32-i386
+RELEASE_CLANGDWARF_IA32_DLINK2_FLAGS = DEF(GCC5_IA32_DLINK2_FLAGS) -O3
+
+NOOPT_CLANGDWARF_IA32_CC_FLAGS = DEF(CLANGDWARF_ALL_CC_FLAGS) -m32 -O0 -march=i586 DEF(CLANGDWARF_IA32_TARGET) -g -malign-double
+NOOPT_CLANGDWARF_IA32_DLINK_FLAGS = DEF(GCC5_IA32_X64_DLINK_FLAGS) -Wl,-O0 -Wl,-melf_i386 -Wl,--oformat=elf32-i386
+NOOPT_CLANGDWARF_IA32_DLINK2_FLAGS = DEF(GCC5_IA32_DLINK2_FLAGS) -O0
##########################
-# CLANG38 X64 definitions
+# CLANGDWARF X64 definitions
##########################
-*_CLANG38_X64_OBJCOPY_PATH = objcopy
-*_CLANG38_X64_CC_PATH = DEF(CLANG38_X64_PREFIX)clang
-*_CLANG38_X64_SLINK_PATH = DEF(CLANG38_X64_PREFIX)llvm-ar
-*_CLANG38_X64_DLINK_PATH = DEF(CLANG38_X64_PREFIX)clang
-*_CLANG38_X64_ASLDLINK_PATH = DEF(CLANG38_X64_PREFIX)clang
-*_CLANG38_X64_ASM_PATH = DEF(CLANG38_X64_PREFIX)clang
-*_CLANG38_X64_PP_PATH = DEF(CLANG38_X64_PREFIX)clang
-*_CLANG38_X64_VFRPP_PATH = DEF(CLANG38_X64_PREFIX)clang
-*_CLANG38_X64_ASLCC_PATH = DEF(CLANG38_X64_PREFIX)clang
-*_CLANG38_X64_ASLPP_PATH = DEF(CLANG38_X64_PREFIX)clang
-*_CLANG38_X64_RC_PATH = objcopy
-
-*_CLANG38_X64_ASLCC_FLAGS = DEF(GCC_ASLCC_FLAGS) -m64 -fno-lto DEF(CLANG38_X64_TARGET)
-*_CLANG38_X64_ASLDLINK_FLAGS = DEF(GCC5_IA32_X64_ASLDLINK_FLAGS) -Wl,-m,elf_x86_64
-*_CLANG38_X64_ASM_FLAGS = DEF(GCC5_ASM_FLAGS) -m64 DEF(CLANG38_X64_TARGET)
-*_CLANG38_X64_RC_FLAGS = DEF(GCC_X64_RC_FLAGS)
-*_CLANG38_X64_OBJCOPY_FLAGS =
-*_CLANG38_X64_NASM_FLAGS = -f elf64
-*_CLANG38_X64_PP_FLAGS = DEF(GCC_PP_FLAGS) DEF(CLANG38_X64_TARGET)
-*_CLANG38_X64_ASLPP_FLAGS = DEF(GCC_ASLPP_FLAGS) DEF(CLANG38_X64_TARGET)
-*_CLANG38_X64_VFRPP_FLAGS = DEF(GCC_VFRPP_FLAGS) DEF(CLANG38_X64_TARGET)
-
-DEBUG_CLANG38_X64_CC_FLAGS = DEF(CLANG38_ALL_CC_FLAGS) -m64 "-DEFIAPI=__attribute__((ms_abi))" -mno-red-zone -mcmodel=small -fpie -Oz -flto DEF(CLANG38_X64_TARGET) -g
-DEBUG_CLANG38_X64_DLINK_FLAGS = DEF(GCC5_IA32_X64_DLINK_FLAGS) -flto -Wl,-Oz -Wl,-melf_x86_64 -Wl,--oformat=elf64-x86-64 -Wl,-pie -mcmodel=small
-DEBUG_CLANG38_X64_DLINK2_FLAGS = DEF(GCC5_X64_DLINK2_FLAGS) -O3
-
-RELEASE_CLANG38_X64_CC_FLAGS = DEF(CLANG38_ALL_CC_FLAGS) -m64 "-DEFIAPI=__attribute__((ms_abi))" -mno-red-zone -mcmodel=small -fpie -Oz -flto DEF(CLANG38_X64_TARGET)
-RELEASE_CLANG38_X64_DLINK_FLAGS = DEF(GCC5_IA32_X64_DLINK_FLAGS) -flto -Wl,-Oz -Wl,-melf_x86_64 -Wl,--oformat=elf64-x86-64 -Wl,-pie -mcmodel=small
-RELEASE_CLANG38_X64_DLINK2_FLAGS = DEF(GCC5_X64_DLINK2_FLAGS) -O3
-
-NOOPT_CLANG38_X64_CC_FLAGS = DEF(CLANG38_ALL_CC_FLAGS) -m64 "-DEFIAPI=__attribute__((ms_abi))" -mno-red-zone -mcmodel=small -fpie -O0 DEF(CLANG38_X64_TARGET) -g
-NOOPT_CLANG38_X64_DLINK_FLAGS = DEF(GCC5_IA32_X64_DLINK_FLAGS) -Wl,-O0 -Wl,-melf_x86_64 -Wl,--oformat=elf64-x86-64 -Wl,-pie -mcmodel=small
-NOOPT_CLANG38_X64_DLINK2_FLAGS = DEF(GCC5_X64_DLINK2_FLAGS) -O0
+*_CLANGDWARF_X64_OBJCOPY_PATH = objcopy
+*_CLANGDWARF_X64_CC_PATH = DEF(CLANGDWARF_X64_PREFIX)clang
+*_CLANGDWARF_X64_SLINK_PATH = DEF(CLANGDWARF_X64_PREFIX)llvm-ar
+*_CLANGDWARF_X64_DLINK_PATH = DEF(CLANGDWARF_X64_PREFIX)clang
+*_CLANGDWARF_X64_ASLDLINK_PATH = DEF(CLANGDWARF_X64_PREFIX)clang
+*_CLANGDWARF_X64_ASM_PATH = DEF(CLANGDWARF_X64_PREFIX)clang
+*_CLANGDWARF_X64_PP_PATH = DEF(CLANGDWARF_X64_PREFIX)clang
+*_CLANGDWARF_X64_VFRPP_PATH = DEF(CLANGDWARF_X64_PREFIX)clang
+*_CLANGDWARF_X64_ASLCC_PATH = DEF(CLANGDWARF_X64_PREFIX)clang
+*_CLANGDWARF_X64_ASLPP_PATH = DEF(CLANGDWARF_X64_PREFIX)clang
+*_CLANGDWARF_X64_RC_PATH = objcopy
+
+*_CLANGDWARF_X64_ASLCC_FLAGS = DEF(GCC_ASLCC_FLAGS) -m64 -fno-lto DEF(CLANGDWARF_X64_TARGET)
+*_CLANGDWARF_X64_ASLDLINK_FLAGS = DEF(GCC5_IA32_X64_ASLDLINK_FLAGS) -Wl,-m,elf_x86_64
+*_CLANGDWARF_X64_ASM_FLAGS = DEF(GCC5_ASM_FLAGS) -m64 DEF(CLANGDWARF_X64_TARGET)
+*_CLANGDWARF_X64_RC_FLAGS = DEF(GCC_X64_RC_FLAGS)
+*_CLANGDWARF_X64_OBJCOPY_FLAGS =
+*_CLANGDWARF_X64_NASM_FLAGS = -f elf64
+*_CLANGDWARF_X64_PP_FLAGS = DEF(GCC_PP_FLAGS) DEF(CLANGDWARF_X64_TARGET)
+*_CLANGDWARF_X64_ASLPP_FLAGS = DEF(GCC_ASLPP_FLAGS) DEF(CLANGDWARF_X64_TARGET)
+*_CLANGDWARF_X64_VFRPP_FLAGS = DEF(GCC_VFRPP_FLAGS) DEF(CLANGDWARF_X64_TARGET)
+
+DEBUG_CLANGDWARF_X64_CC_FLAGS = DEF(CLANGDWARF_ALL_CC_FLAGS) -m64 "-DEFIAPI=__attribute__((ms_abi))" -mno-red-zone -mcmodel=small -fpie -Oz -flto DEF(CLANGDWARF_X64_TARGET) -g
+DEBUG_CLANGDWARF_X64_DLINK_FLAGS = DEF(GCC5_IA32_X64_DLINK_FLAGS) -flto -Wl,-Oz -Wl,-melf_x86_64 -Wl,--oformat=elf64-x86-64 -Wl,-pie -mcmodel=small
+DEBUG_CLANGDWARF_X64_DLINK2_FLAGS = DEF(GCC5_X64_DLINK2_FLAGS) -O3
+
+RELEASE_CLANGDWARF_X64_CC_FLAGS = DEF(CLANGDWARF_ALL_CC_FLAGS) -m64 "-DEFIAPI=__attribute__((ms_abi))" -mno-red-zone -mcmodel=small -fpie -Oz -flto DEF(CLANGDWARF_X64_TARGET)
+RELEASE_CLANGDWARF_X64_DLINK_FLAGS = DEF(GCC5_IA32_X64_DLINK_FLAGS) -flto -Wl,-O3 -Wl,-melf_x86_64 -Wl,--oformat=elf64-x86-64 -Wl,-pie -mcmodel=small -fuse-ld=lld
+RELEASE_CLANGDWARF_X64_DLINK2_FLAGS = DEF(GCC5_X64_DLINK2_FLAGS) -O3 -fuse-ld=lld
+
+NOOPT_CLANGDWARF_X64_CC_FLAGS = DEF(CLANGDWARF_ALL_CC_FLAGS) -m64 "-DEFIAPI=__attribute__((ms_abi))" -mno-red-zone -mcmodel=small -fpie -O0 DEF(CLANGDWARF_X64_TARGET) -g
+NOOPT_CLANGDWARF_X64_DLINK_FLAGS = DEF(GCC5_IA32_X64_DLINK_FLAGS) -flto -Wl,-O0 -Wl,-melf_x86_64 -Wl,--oformat=elf64-x86-64 -Wl,-pie -mcmodel=small
+NOOPT_CLANGDWARF_X64_DLINK2_FLAGS = DEF(GCC5_X64_DLINK2_FLAGS) -O0
##################
-# CLANG38 ARM definitions
+# CLANGDWARF ARM definitions
##################
-DEFINE CLANG38_ARM_TARGET = -target arm-linux-gnueabi
-DEFINE CLANG38_ARM_CC_FLAGS = DEF(GCC_ARM_CC_FLAGS) DEF(CLANG38_ARM_TARGET) DEF(CLANG38_WARNING_OVERRIDES) -mno-movt
-DEFINE CLANG38_ARM_DLINK_FLAGS = DEF(CLANG38_ARM_TARGET) DEF(GCC_ARM_DLINK_FLAGS)
-
-*_CLANG38_ARM_PP_FLAGS = DEF(GCC_PP_FLAGS)
-*_CLANG38_ARM_ASLCC_FLAGS = DEF(GCC_ASLCC_FLAGS)
-*_CLANG38_ARM_APP_FLAGS =
-*_CLANG38_ARM_ASL_FLAGS = DEF(IASL_FLAGS)
-*_CLANG38_ARM_ASL_OUTFLAGS = DEF(IASL_OUTFLAGS)
-*_CLANG38_ARM_DTCPP_FLAGS = DEF(GCC_DTCPP_FLAGS)
-
-*_CLANG38_ARM_CC_PATH = ENV(CLANG38_BIN)clang
-*_CLANG38_ARM_ASM_PATH = ENV(CLANG38_BIN)clang
-*_CLANG38_ARM_PP_PATH = ENV(CLANG38_BIN)clang
-*_CLANG38_ARM_VFRPP_PATH = ENV(CLANG38_BIN)clang
-*_CLANG38_ARM_ASLCC_PATH = ENV(CLANG38_BIN)clang
-*_CLANG38_ARM_ASLPP_PATH = ENV(CLANG38_BIN)clang
-*_CLANG38_ARM_DLINK_PATH = ENV(CLANG38_BIN)clang
-*_CLANG38_ARM_ASLDLINK_PATH = ENV(CLANG38_BIN)clang
-
-*_CLANG38_ARM_SLINK_PATH = ENV(CLANG38_BIN)llvm-ar
-*_CLANG38_ARM_RC_PATH = ENV(CLANG38_ARM_PREFIX)objcopy
-
-*_CLANG38_ARM_ASLCC_FLAGS = DEF(GCC_ASLCC_FLAGS) -fno-lto
-*_CLANG38_ARM_ASLDLINK_FLAGS = DEF(CLANG38_ARM_TARGET) DEF(GCC_ARM_ASLDLINK_FLAGS)
-*_CLANG38_ARM_ASM_FLAGS = DEF(GCC_ASM_FLAGS) DEF(CLANG38_ARM_TARGET) $(PLATFORM_FLAGS) -Qunused-arguments
-*_CLANG38_ARM_DLINK2_FLAGS = DEF(GCC_DLINK2_FLAGS_COMMON) -Wl,--defsym=PECOFF_HEADER_SIZE=0x220
-*_CLANG38_ARM_PLATFORM_FLAGS = -march=armv7-a
-*_CLANG38_ARM_PP_FLAGS = DEF(GCC_PP_FLAGS) DEF(CLANG38_ARM_TARGET) $(PLATFORM_FLAGS)
-*_CLANG38_ARM_RC_FLAGS = DEF(GCC_ARM_RC_FLAGS)
-*_CLANG38_ARM_VFRPP_FLAGS = DEF(GCC_VFRPP_FLAGS) DEF(CLANG38_ARM_TARGET) $(PLATFORM_FLAGS)
-*_CLANG38_ARM_ASLPP_FLAGS = DEF(GCC_ASLPP_FLAGS) DEF(CLANG38_ARM_TARGET)
-*_CLANG38_ARM_CC_XIPFLAGS = DEF(GCC_ARM_CC_XIPFLAGS)
-
- DEBUG_CLANG38_ARM_CC_FLAGS = DEF(CLANG38_ARM_CC_FLAGS) $(PLATFORM_FLAGS) -flto -O1
- DEBUG_CLANG38_ARM_DLINK_FLAGS = DEF(CLANG38_ARM_DLINK_FLAGS) -flto -Wl,-O1 -L$(WORKSPACE)/ArmPkg/Library/GccLto -llto-arm -Wl,-plugin-opt=-pass-through=-llto-arm
- NOOPT_CLANG38_ARM_CC_FLAGS = DEF(CLANG38_ARM_CC_FLAGS) $(PLATFORM_FLAGS) -O0
- NOOPT_CLANG38_ARM_DLINK_FLAGS = DEF(CLANG38_ARM_DLINK_FLAGS)
-RELEASE_CLANG38_ARM_CC_FLAGS = DEF(CLANG38_ARM_CC_FLAGS) $(PLATFORM_FLAGS) -flto -O3
-RELEASE_CLANG38_ARM_DLINK_FLAGS = DEF(CLANG38_ARM_DLINK_FLAGS) -flto -Wl,-O3 -L$(WORKSPACE)/ArmPkg/Library/GccLto -llto-arm -Wl,-plugin-opt=-pass-through=-llto-arm
+DEFINE CLANGDWARF_ARM_TARGET = -target arm-linux-gnueabi
+DEFINE CLANGDWARF_ARM_CC_FLAGS = $(PLATFORM_FLAGS) DEF(GCC_ALL_CC_FLAGS) -mlittle-endian -mabi=aapcs -fno-short-enums -funsigned-char -fomit-frame-pointer -Wno-address -mthumb -fno-pic -fno-pie DEF(CLANGDWARF_ARM_TARGET) DEF(CLANGDWARF_WARNING_OVERRIDES) -mno-movt
+DEFINE CLANGDWARF_ARM_DLINK_FLAGS = DEF(CLANGDWARF_ARM_TARGET) DEF(GCC_ARM_DLINK_FLAGS)
+
+*_CLANGDWARF_ARM_PP_FLAGS = DEF(GCC_PP_FLAGS)
+*_CLANGDWARF_ARM_ASLCC_FLAGS = DEF(GCC_ASLCC_FLAGS)
+*_CLANGDWARF_ARM_APP_FLAGS =
+*_CLANGDWARF_ARM_ASL_FLAGS = DEF(IASL_FLAGS)
+*_CLANGDWARF_ARM_ASL_OUTFLAGS = DEF(IASL_OUTFLAGS)
+*_CLANGDWARF_ARM_DTCPP_FLAGS = DEF(GCC_DTCPP_FLAGS)
+
+*_CLANGDWARF_ARM_CC_PATH = ENV(CLANGDWARF_BIN)clang
+*_CLANGDWARF_ARM_ASM_PATH = ENV(CLANGDWARF_BIN)clang
+*_CLANGDWARF_ARM_PP_PATH = ENV(CLANGDWARF_BIN)clang
+*_CLANGDWARF_ARM_VFRPP_PATH = ENV(CLANGDWARF_BIN)clang
+*_CLANGDWARF_ARM_ASLCC_PATH = ENV(CLANGDWARF_BIN)clang
+*_CLANGDWARF_ARM_ASLPP_PATH = ENV(CLANGDWARF_BIN)clang
+*_CLANGDWARF_ARM_DLINK_PATH = ENV(CLANGDWARF_BIN)clang
+*_CLANGDWARF_ARM_ASLDLINK_PATH = ENV(CLANGDWARF_BIN)clang
+
+*_CLANGDWARF_ARM_SLINK_PATH = ENV(CLANGDWARF_BIN)llvm-ar
+*_CLANGDWARF_ARM_RC_PATH = ENV(CLANGDWARF_ARM_PREFIX)objcopy
+
+*_CLANGDWARF_ARM_ASLCC_FLAGS = DEF(GCC_ASLCC_FLAGS) -fno-lto
+*_CLANGDWARF_ARM_ASLDLINK_FLAGS = DEF(CLANGDWARF_ARM_TARGET) DEF(GCC_ARM_ASLDLINK_FLAGS)
+*_CLANGDWARF_ARM_ASM_FLAGS = DEF(GCC_ASM_FLAGS) DEF(CLANGDWARF_ARM_TARGET) $(PLATFORM_FLAGS) -Qunused-arguments
+*_CLANGDWARF_ARM_DLINK2_FLAGS = DEF(GCC_DLINK2_FLAGS_COMMON) -Wl,--defsym=PECOFF_HEADER_SIZE=0x220
+*_CLANGDWARF_ARM_PLATFORM_FLAGS = -march=armv7-a
+*_CLANGDWARF_ARM_PP_FLAGS = DEF(GCC_PP_FLAGS) DEF(CLANGDWARF_ARM_TARGET) $(PLATFORM_FLAGS)
+*_CLANGDWARF_ARM_RC_FLAGS = DEF(GCC_ARM_RC_FLAGS)
+*_CLANGDWARF_ARM_VFRPP_FLAGS = DEF(GCC_VFRPP_FLAGS) DEF(CLANGDWARF_ARM_TARGET) $(PLATFORM_FLAGS)
+*_CLANGDWARF_ARM_ASLPP_FLAGS = DEF(GCC_ASLPP_FLAGS) DEF(CLANGDWARF_ARM_TARGET)
+*_CLANGDWARF_ARM_CC_XIPFLAGS = DEF(GCC_ARM_CC_XIPFLAGS)
+
+ DEBUG_CLANGDWARF_ARM_CC_FLAGS = DEF(CLANGDWARF_ARM_CC_FLAGS) $(PLATFORM_FLAGS) -flto -O1
+ DEBUG_CLANGDWARF_ARM_DLINK_FLAGS = DEF(CLANGDWARF_ARM_DLINK_FLAGS) -flto -Wl,-O1 -L$(WORKSPACE)/ArmPkg/Library/GccLto -llto-arm -Wl,-plugin-opt=-pass-through=-llto-arm
+ NOOPT_CLANGDWARF_ARM_CC_FLAGS = DEF(CLANGDWARF_ARM_CC_FLAGS) $(PLATFORM_FLAGS) -O0
+ NOOPT_CLANGDWARF_ARM_DLINK_FLAGS = DEF(CLANGDWARF_ARM_DLINK_FLAGS)
+RELEASE_CLANGDWARF_ARM_CC_FLAGS = DEF(CLANGDWARF_ARM_CC_FLAGS) $(PLATFORM_FLAGS) -flto -O3
+RELEASE_CLANGDWARF_ARM_DLINK_FLAGS = DEF(CLANGDWARF_ARM_DLINK_FLAGS)
+-flto -Wl,-O3 -L$(WORKSPACE)/ArmPkg/Library/GccLto -llto-arm
+-Wl,-plugin-opt=-pass-through=-llto-arm
##################
-# CLANG38 AARCH64 definitions
+# CLANGDWARF AARCH64 definitions
##################
-DEFINE CLANG38_AARCH64_TARGET = -target aarch64-linux-gnu
-DEFINE CLANG38_AARCH64_CC_FLAGS = DEF(GCC_AARCH64_CC_FLAGS) DEF(CLANG38_AARCH64_TARGET) -mcmodel=small DEF(CLANG38_WARNING_OVERRIDES) -DEFINE CLANG38_AARCH64_DLINK_FLAGS = DEF(CLANG38_AARCH64_TARGET) DEF(GCC_AARCH64_DLINK_FLAGS) -z common-page-size=0x1000
-
-*_CLANG38_AARCH64_PP_FLAGS = DEF(GCC_PP_FLAGS)
-*_CLANG38_AARCH64_ASLCC_FLAGS = DEF(GCC_ASLCC_FLAGS)
-*_CLANG38_AARCH64_APP_FLAGS =
-*_CLANG38_AARCH64_ASL_FLAGS = DEF(IASL_FLAGS)
-*_CLANG38_AARCH64_ASL_OUTFLAGS = DEF(IASL_OUTFLAGS)
-*_CLANG38_AARCH64_DTCPP_FLAGS = DEF(GCC_DTCPP_FLAGS)
-
-*_CLANG38_AARCH64_CC_PATH = ENV(CLANG38_BIN)clang
-*_CLANG38_AARCH64_ASM_PATH = ENV(CLANG38_BIN)clang
-*_CLANG38_AARCH64_PP_PATH = ENV(CLANG38_BIN)clang
-*_CLANG38_AARCH64_VFRPP_PATH = ENV(CLANG38_BIN)clang
-*_CLANG38_AARCH64_ASLCC_PATH = ENV(CLANG38_BIN)clang
-*_CLANG38_AARCH64_ASLPP_PATH = ENV(CLANG38_BIN)clang
-*_CLANG38_AARCH64_DLINK_PATH = ENV(CLANG38_BIN)clang
-*_CLANG38_AARCH64_ASLDLINK_PATH = ENV(CLANG38_BIN)clang
-
-*_CLANG38_AARCH64_SLINK_PATH = ENV(CLANG38_BIN)llvm-ar
-*_CLANG38_AARCH64_RC_PATH = ENV(CLANG38_AARCH64_PREFIX)objcopy
-
-*_CLANG38_AARCH64_ASLCC_FLAGS = DEF(GCC_ASLCC_FLAGS) -fno-lto
-*_CLANG38_AARCH64_ASLDLINK_FLAGS = DEF(CLANG38_AARCH64_TARGET) DEF(GCC_AARCH64_ASLDLINK_FLAGS)
-*_CLANG38_AARCH64_ASM_FLAGS = DEF(GCC_ASM_FLAGS) DEF(CLANG38_AARCH64_TARGET) $(PLATFORM_FLAGS) -Qunused-arguments
-*_CLANG38_AARCH64_DLINK_FLAGS = DEF(CLANG38_AARCH64_TARGET) DEF(GCC_AARCH64_DLINK_FLAGS) -z common-page-size=0x1000
-*_CLANG38_AARCH64_DLINK_XIPFLAGS = -z common-page-size=0x20
-*_CLANG38_AARCH64_DLINK2_FLAGS = DEF(GCC_DLINK2_FLAGS_COMMON) -Wl,--defsym=PECOFF_HEADER_SIZE=0x228
-*_CLANG38_AARCH64_PLATFORM_FLAGS =
-*_CLANG38_AARCH64_PP_FLAGS = DEF(GCC_PP_FLAGS) DEF(CLANG38_AARCH64_TARGET) $(PLATFORM_FLAGS)
-*_CLANG38_AARCH64_RC_FLAGS = DEF(GCC_AARCH64_RC_FLAGS)
-*_CLANG38_AARCH64_VFRPP_FLAGS = DEF(GCC_VFRPP_FLAGS) DEF(CLANG38_AARCH64_TARGET) $(PLATFORM_FLAGS)
-*_CLANG38_AARCH64_ASLPP_FLAGS = DEF(GCC_ASLPP_FLAGS) DEF(CLANG38_AARCH64_TARGET)
-*_CLANG38_AARCH64_CC_XIPFLAGS = DEF(GCC_AARCH64_CC_XIPFLAGS)
-
- DEBUG_CLANG38_AARCH64_CC_FLAGS = DEF(CLANG38_AARCH64_CC_FLAGS) $(PLATFORM_FLAGS) -flto -O1
- DEBUG_CLANG38_AARCH64_DLINK_FLAGS = DEF(CLANG38_AARCH64_DLINK_FLAGS) -flto -Wl,-O1 -L$(WORKSPACE)/ArmPkg/Library/GccLto -llto-aarch64 -Wl,-plugin-opt=-pass-through=-llto-aarch64
- NOOPT_CLANG38_AARCH64_CC_FLAGS = DEF(CLANG38_AARCH64_CC_FLAGS) $(PLATFORM_FLAGS) -O0
- NOOPT_CLANG38_AARCH64_DLINK_FLAGS = DEF(CLANG38_AARCH64_DLINK_FLAGS)
-RELEASE_CLANG38_AARCH64_CC_FLAGS = DEF(CLANG38_AARCH64_CC_FLAGS) $(PLATFORM_FLAGS) -flto -O3
-RELEASE_CLANG38_AARCH64_DLINK_FLAGS = DEF(CLANG38_AARCH64_DLINK_FLAGS) -flto -Wl,-O3 -L$(WORKSPACE)/ArmPkg/Library/GccLto -llto-aarch64 -Wl,-plugin-opt=-pass-through=-llto-aarch64
+DEFINE CLANGDWARF_AARCH64_TARGET = -target aarch64-linux-gnu
+DEFINE CLANGDWARF_AARCH64_CC_FLAGS = DEF(GCC_AARCH64_CC_FLAGS)
+DEF(CLANGDWARF_AARCH64_TARGET) -mcmodel=small
+DEF(CLANGDWARF_WARNING_OVERRIDES) DEFINE CLANGDWARF_AARCH64_DLINK_FLAGS
+= DEF(CLANGDWARF_AARCH64_TARGET) DEF(GCC_AARCH64_DLINK_FLAGS) -z
+common-page-size=0x1000
+
+*_CLANGDWARF_AARCH64_PP_FLAGS = DEF(GCC_PP_FLAGS)
+*_CLANGDWARF_AARCH64_ASLCC_FLAGS = DEF(GCC_ASLCC_FLAGS)
+*_CLANGDWARF_AARCH64_APP_FLAGS =
+*_CLANGDWARF_AARCH64_ASL_FLAGS = DEF(IASL_FLAGS)
+*_CLANGDWARF_AARCH64_ASL_OUTFLAGS = DEF(IASL_OUTFLAGS)
+*_CLANGDWARF_AARCH64_DTCPP_FLAGS = DEF(GCC_DTCPP_FLAGS)
+
+*_CLANGDWARF_AARCH64_CC_PATH = ENV(CLANGDWARF_BIN)clang
+*_CLANGDWARF_AARCH64_ASM_PATH = ENV(CLANGDWARF_BIN)clang
+*_CLANGDWARF_AARCH64_PP_PATH = ENV(CLANGDWARF_BIN)clang
+*_CLANGDWARF_AARCH64_VFRPP_PATH = ENV(CLANGDWARF_BIN)clang
+*_CLANGDWARF_AARCH64_ASLCC_PATH = ENV(CLANGDWARF_BIN)clang
+*_CLANGDWARF_AARCH64_ASLPP_PATH = ENV(CLANGDWARF_BIN)clang
+*_CLANGDWARF_AARCH64_DLINK_PATH = ENV(CLANGDWARF_BIN)clang
+*_CLANGDWARF_AARCH64_ASLDLINK_PATH = ENV(CLANGDWARF_BIN)clang
+
+*_CLANGDWARF_AARCH64_SLINK_PATH = ENV(CLANGDWARF_BIN)llvm-ar
+*_CLANGDWARF_AARCH64_RC_PATH = ENV(CLANGDWARF_AARCH64_PREFIX)objcopy
+
+*_CLANGDWARF_AARCH64_ASLCC_FLAGS = DEF(GCC_ASLCC_FLAGS) -fno-lto
+*_CLANGDWARF_AARCH64_ASLDLINK_FLAGS = DEF(CLANGDWARF_AARCH64_TARGET) DEF(GCC_AARCH64_ASLDLINK_FLAGS)
+*_CLANGDWARF_AARCH64_ASM_FLAGS = DEF(GCC_ASM_FLAGS) DEF(CLANGDWARF_AARCH64_TARGET) $(PLATFORM_FLAGS) -Qunused-arguments
+*_CLANGDWARF_AARCH64_DLINK_FLAGS = DEF(CLANGDWARF_AARCH64_TARGET) DEF(GCC_AARCH64_DLINK_FLAGS) -z common-page-size=0x1000
+*_CLANGDWARF_AARCH64_DLINK_XIPFLAGS = -z common-page-size=0x20
+*_CLANGDWARF_AARCH64_DLINK2_FLAGS = DEF(GCC_DLINK2_FLAGS_COMMON) -Wl,--defsym=PECOFF_HEADER_SIZE=0x228
+*_CLANGDWARF_AARCH64_PLATFORM_FLAGS =
+*_CLANGDWARF_AARCH64_PP_FLAGS = DEF(GCC_PP_FLAGS) DEF(CLANGDWARF_AARCH64_TARGET) $(PLATFORM_FLAGS)
+*_CLANGDWARF_AARCH64_RC_FLAGS = DEF(GCC_AARCH64_RC_FLAGS)
+*_CLANGDWARF_AARCH64_VFRPP_FLAGS = DEF(GCC_VFRPP_FLAGS) DEF(CLANGDWARF_AARCH64_TARGET) $(PLATFORM_FLAGS)
+*_CLANGDWARF_AARCH64_ASLPP_FLAGS = DEF(GCC_ASLPP_FLAGS) DEF(CLANGDWARF_AARCH64_TARGET)
+*_CLANGDWARF_AARCH64_CC_XIPFLAGS = DEF(GCC_AARCH64_CC_XIPFLAGS)
+
+ DEBUG_CLANGDWARF_AARCH64_CC_FLAGS = DEF(CLANGDWARF_AARCH64_CC_FLAGS) $(PLATFORM_FLAGS) -flto -O1
+ DEBUG_CLANGDWARF_AARCH64_DLINK_FLAGS = DEF(CLANGDWARF_AARCH64_DLINK_FLAGS) -flto -Wl,-O1 -L$(WORKSPACE)/ArmPkg/Library/GccLto -llto-aarch64 -Wl,-plugin-opt=-pass-through=-llto-aarch64
+ NOOPT_CLANGDWARF_AARCH64_CC_FLAGS = DEF(CLANGDWARF_AARCH64_CC_FLAGS) $(PLATFORM_FLAGS) -O0
+ NOOPT_CLANGDWARF_AARCH64_DLINK_FLAGS = DEF(CLANGDWARF_AARCH64_DLINK_FLAGS)
+RELEASE_CLANGDWARF_AARCH64_CC_FLAGS = DEF(CLANGDWARF_AARCH64_CC_FLAGS) $(PLATFORM_FLAGS) -flto -O3
+RELEASE_CLANGDWARF_AARCH64_DLINK_FLAGS =
+DEF(CLANGDWARF_AARCH64_DLINK_FLAGS) -flto -Wl,-O3
+-L$(WORKSPACE)/ArmPkg/Library/GccLto -llto-aarch64
+-Wl,-plugin-opt=-pass-through=-llto-aarch64
####################################################################################
#
@@ -2763,106 +2752,6 @@ NOOPT_CLANGPDB_X64_DLINK_FLAGS = /NOLOGO /NODEFAULTLIB /IGNORE:4001 /OPT:RE
NOOPT_CLANGPDB_X64_DLINK2_FLAGS =
NOOPT_CLANGPDB_X64_GENFW_FLAGS = --keepexceptiontable
-####################################################################################
-#
-# CLANGDWARF - This configuration is used to compile under Windows/Linux/Mac to produce -# ELF binaries using LLVM/Clang/LLD with Link Time Optimization enabled -# -####################################################################################
-*_CLANGDWARF_*_*_FAMILY = GCC
-*_CLANGDWARF_*_*_BUILDRULEFAMILY = CLANGGCC
-*_CLANGDWARF_*_MAKE_PATH = ENV(CLANG_HOST_BIN)make
-*_CLANGDWARF_*_*_DLL = ENV(CLANGDWARF_DLL)
-*_CLANGDWARF_*_ASL_PATH = DEF(UNIX_IASL_BIN)
-
-*_CLANGDWARF_*_APP_FLAGS =
-*_CLANGDWARF_*_ASL_FLAGS = DEF(IASL_FLAGS)
-*_CLANGDWARF_*_ASL_OUTFLAGS = DEF(IASL_OUTFLAGS)
-
-DEFINE CLANGDWARF_IA32_PREFIX = ENV(CLANG_BIN)
-DEFINE CLANGDWARF_X64_PREFIX = ENV(CLANG_BIN)
-
-# LLVM/CLANG doesn't support -n link option. So, it can't share the same IA32_X64_DLINK_COMMON flag.
-# LLVM/CLANG doesn't support common page size. So, it can't share the same GccBase.lds script.
-DEFINE CLANGDWARF_IA32_X64_DLINK_COMMON = -nostdlib -Wl,-q,--gc-sections -z max-page-size=0x40
-DEFINE CLANGDWARF_DLINK2_FLAGS_COMMON = -Wl,--script=$(EDK_TOOLS_PATH)/Scripts/ClangBase.lds
-DEFINE CLANGDWARF_IA32_X64_ASLDLINK_FLAGS = DEF(CLANGDWARF_IA32_X64_DLINK_COMMON) -Wl,--defsym=PECOFF_HEADER_SIZE=0 DEF(CLANGDWARF_DLINK2_FLAGS_COMMON) -Wl,--entry,ReferenceAcpiTable -u ReferenceAcpiTable
-DEFINE CLANGDWARF_IA32_X64_DLINK_FLAGS = DEF(CLANGDWARF_IA32_X64_DLINK_COMMON) -Wl,--entry,$(IMAGE_ENTRY_POINT) -u $(IMAGE_ENTRY_POINT) -Wl,-Map,$(DEST_DIR_DEBUG)/$(BASE_NAME).map,--whole-archive
-DEFINE CLANGDWARF_IA32_DLINK2_FLAGS = -Wl,--defsym=PECOFF_HEADER_SIZE=0x220 DEF(CLANGDWARF_DLINK2_FLAGS_COMMON)
-DEFINE CLANGDWARF_X64_DLINK2_FLAGS = -Wl,--defsym=PECOFF_HEADER_SIZE=0x228 DEF(CLANGDWARF_DLINK2_FLAGS_COMMON)
-
-###########################
-# CLANGDWARF IA32 definitions
-###########################
-*_CLANGDWARF_IA32_CC_PATH = DEF(CLANGDWARF_IA32_PREFIX)clang
-*_CLANGDWARF_IA32_SLINK_PATH = DEF(CLANGDWARF_IA32_PREFIX)llvm-ar
-*_CLANGDWARF_IA32_DLINK_PATH = DEF(CLANGDWARF_IA32_PREFIX)clang
-*_CLANGDWARF_IA32_ASLDLINK_PATH = DEF(CLANGDWARF_IA32_PREFIX)clang
-*_CLANGDWARF_IA32_ASM_PATH = DEF(CLANGDWARF_IA32_PREFIX)clang
-*_CLANGDWARF_IA32_PP_PATH = DEF(CLANGDWARF_IA32_PREFIX)clang
-*_CLANGDWARF_IA32_VFRPP_PATH = DEF(CLANGDWARF_IA32_PREFIX)clang
-*_CLANGDWARF_IA32_ASLCC_PATH = DEF(CLANGDWARF_IA32_PREFIX)clang
-*_CLANGDWARF_IA32_ASLPP_PATH = DEF(CLANGDWARF_IA32_PREFIX)clang
-*_CLANGDWARF_IA32_RC_PATH = DEF(CLANGDWARF_IA32_PREFIX)llvm-rc
-
-*_CLANGDWARF_IA32_ASLCC_FLAGS = DEF(GCC_ASLCC_FLAGS) -m32 -fno-lto DEF(CLANG38_IA32_TARGET)
-*_CLANGDWARF_IA32_ASLDLINK_FLAGS = DEF(CLANGDWARF_IA32_X64_ASLDLINK_FLAGS) -Wl,-m,elf_i386 -fuse-ld=lld
-*_CLANGDWARF_IA32_ASM_FLAGS = DEF(GCC5_ASM_FLAGS) -m32 -march=i386 DEF(CLANG38_IA32_TARGET)
-*_CLANGDWARF_IA32_RC_FLAGS = DEF(GCC_IA32_RC_FLAGS)
-*_CLANGDWARF_IA32_OBJCOPY_FLAGS =
-*_CLANGDWARF_IA32_NASM_FLAGS = -f elf32
-*_CLANGDWARF_IA32_PP_FLAGS = DEF(GCC_PP_FLAGS) DEF(CLANG38_IA32_TARGET)
-*_CLANGDWARF_IA32_ASLPP_FLAGS = DEF(GCC_ASLPP_FLAGS) DEF(CLANG38_IA32_TARGET)
-*_CLANGDWARF_IA32_VFRPP_FLAGS = DEF(GCC_VFRPP_FLAGS) DEF(CLANG38_IA32_TARGET)
-
-DEBUG_CLANGDWARF_IA32_CC_FLAGS = DEF(CLANG38_ALL_CC_FLAGS) -m32 -Oz -flto -march=i586 DEF(CLANG38_IA32_TARGET) -g -malign-double
-DEBUG_CLANGDWARF_IA32_DLINK_FLAGS = DEF(CLANGDWARF_IA32_X64_DLINK_FLAGS) -flto -Wl,-O3 -Wl,-melf_i386 -Wl,--oformat,elf32-i386
-DEBUG_CLANGDWARF_IA32_DLINK2_FLAGS = DEF(CLANGDWARF_IA32_DLINK2_FLAGS) -O3 -fuse-ld=lld
-
-RELEASE_CLANGDWARF_IA32_CC_FLAGS = DEF(CLANG38_ALL_CC_FLAGS) -m32 -Oz -flto -march=i586 DEF(CLANG38_IA32_TARGET) -malign-double
-RELEASE_CLANGDWARF_IA32_DLINK_FLAGS = DEF(CLANGDWARF_IA32_X64_DLINK_FLAGS) -flto -Wl,-O3 -Wl,-melf_i386 -Wl,--oformat,elf32-i386
-RELEASE_CLANGDWARF_IA32_DLINK2_FLAGS = DEF(CLANGDWARF_IA32_DLINK2_FLAGS) -O3 -fuse-ld=lld
-
-NOOPT_CLANGDWARF_IA32_CC_FLAGS = DEF(CLANG38_ALL_CC_FLAGS) -m32 -O0 -march=i586 DEF(CLANG38_IA32_TARGET) -g -malign-double
-NOOPT_CLANGDWARF_IA32_DLINK_FLAGS = DEF(CLANGDWARF_IA32_X64_DLINK_FLAGS) -Wl,-O0 -Wl,-melf_i386 -Wl,--oformat,elf32-i386
-NOOPT_CLANGDWARF_IA32_DLINK2_FLAGS = DEF(CLANGDWARF_IA32_DLINK2_FLAGS) -O0 -fuse-ld=lld
-
-##########################
-# CLANGDWARF X64 definitions
-##########################
-*_CLANGDWARF_X64_CC_PATH = DEF(CLANGDWARF_X64_PREFIX)clang
-*_CLANGDWARF_X64_SLINK_PATH = DEF(CLANGDWARF_X64_PREFIX)llvm-ar
-*_CLANGDWARF_X64_DLINK_PATH = DEF(CLANGDWARF_X64_PREFIX)clang
-*_CLANGDWARF_X64_ASLDLINK_PATH = DEF(CLANGDWARF_X64_PREFIX)clang
-*_CLANGDWARF_X64_ASM_PATH = DEF(CLANGDWARF_X64_PREFIX)clang
-*_CLANGDWARF_X64_PP_PATH = DEF(CLANGDWARF_X64_PREFIX)clang
-*_CLANGDWARF_X64_VFRPP_PATH = DEF(CLANGDWARF_X64_PREFIX)clang
-*_CLANGDWARF_X64_ASLCC_PATH = DEF(CLANGDWARF_X64_PREFIX)clang
-*_CLANGDWARF_X64_ASLPP_PATH = DEF(CLANGDWARF_X64_PREFIX)clang
-*_CLANGDWARF_X64_RC_PATH = DEF(CLANGDWARF_X64_PREFIX)llvm-rc
-
-*_CLANGDWARF_X64_ASLCC_FLAGS = DEF(GCC_ASLCC_FLAGS) -m64 -fno-lto DEF(CLANG38_X64_TARGET)
-*_CLANGDWARF_X64_ASLDLINK_FLAGS = DEF(CLANGDWARF_IA32_X64_ASLDLINK_FLAGS) -Wl,-m,elf_x86_64 -fuse-ld=lld
-*_CLANGDWARF_X64_ASM_FLAGS = DEF(GCC5_ASM_FLAGS) -m64 DEF(CLANG38_X64_TARGET)
-*_CLANGDWARF_X64_RC_FLAGS = DEF(GCC_X64_RC_FLAGS)
-*_CLANGDWARF_X64_OBJCOPY_FLAGS =
-*_CLANGDWARF_X64_NASM_FLAGS = -f elf64
-*_CLANGDWARF_X64_PP_FLAGS = DEF(GCC_PP_FLAGS) DEF(CLANG38_X64_TARGET)
-*_CLANGDWARF_X64_ASLPP_FLAGS = DEF(GCC_ASLPP_FLAGS) DEF(CLANG38_X64_TARGET)
-*_CLANGDWARF_X64_VFRPP_FLAGS = DEF(GCC_VFRPP_FLAGS) DEF(CLANG38_X64_TARGET)
-
-DEBUG_CLANGDWARF_X64_CC_FLAGS = DEF(CLANG38_ALL_CC_FLAGS) -m64 "-DEFIAPI=__attribute__((ms_abi))" -mno-red-zone -mcmodel=small -fpie -Oz -flto DEF(CLANG38_X64_TARGET) -g
-DEBUG_CLANGDWARF_X64_DLINK_FLAGS = DEF(CLANGDWARF_IA32_X64_DLINK_FLAGS) -flto -Wl,-O3 -Wl,-melf_x86_64 -Wl,--oformat,elf64-x86-64 -Wl,-pie -mcmodel=small -Wl,--apply-dynamic-relocs
-DEBUG_CLANGDWARF_X64_DLINK2_FLAGS = DEF(CLANGDWARF_X64_DLINK2_FLAGS) -O3 -fuse-ld=lld
-
-RELEASE_CLANGDWARF_X64_CC_FLAGS = DEF(CLANG38_ALL_CC_FLAGS) -m64 "-DEFIAPI=__attribute__((ms_abi))" -mno-red-zone -mcmodel=small -fpie -Oz -flto DEF(CLANG38_X64_TARGET)
-RELEASE_CLANGDWARF_X64_DLINK_FLAGS = DEF(CLANGDWARF_IA32_X64_DLINK_FLAGS) -flto -Wl,-O3 -Wl,-melf_x86_64 -Wl,--oformat,elf64-x86-64 -Wl,-pie -mcmodel=small -Wl,--apply-dynamic-relocs
-RELEASE_CLANGDWARF_X64_DLINK2_FLAGS = DEF(CLANGDWARF_X64_DLINK2_FLAGS) -O3 -fuse-ld=lld
-
-NOOPT_CLANGDWARF_X64_CC_FLAGS = DEF(CLANG38_ALL_CC_FLAGS) -m64 "-DEFIAPI=__attribute__((ms_abi))" -mno-red-zone -mcmodel=small -fpie -O0 DEF(CLANG38_X64_TARGET) -g
-NOOPT_CLANGDWARF_X64_DLINK_FLAGS = DEF(CLANGDWARF_IA32_X64_DLINK_FLAGS) -Wl,-O0 -Wl,-melf_x86_64 -Wl,--oformat,elf64-x86-64 -Wl,-pie -mcmodel=small -Wl,--apply-dynamic-relocs
-NOOPT_CLANGDWARF_X64_DLINK2_FLAGS = DEF(CLANGDWARF_X64_DLINK2_FLAGS) -O0 -fuse-ld=lld
-
#
#
# XCODE5 support
--
2.34.1
[-- Attachment #1.2: Type: text/html, Size: 83666 bytes --]
[-- Attachment #2: image001.png --]
[-- Type: image/png, Size: 53798 bytes --]
next prev parent reply other threads:[~2023-03-29 9:24 UTC|newest]
Thread overview: 68+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-03-28 17:30 [PATCH v2 00/13] BaseTools,CryptoPkg,MdePkg,OvmfPkg: Delete CLANG35,CLANG38,GCC48,GCC49, rename GCC5 to GCC, update CLANGDWARF, delete VS 2008-2013, EBC Rebecca Cran
2023-03-28 17:30 ` [PATCH v2 01/13] OvmfPkg: Replace static struct initialization with ZeroMem call Rebecca Cran
2023-03-28 22:40 ` Yao, Jiewen
2023-03-28 22:45 ` Michael D Kinney
2023-03-28 17:31 ` [PATCH v2 02/13] CryptoPkg: Add CLANGDWARF and remove CLANG35 and CLANG38 compiler flags Rebecca Cran
2023-03-28 17:31 ` [PATCH v2 03/13] BaseTools: Update CLANGDWARF toolchain and remove CLANG35 and CLANG38 Rebecca Cran
2023-03-29 3:46 ` [edk2-devel] " Guo, Gua
[not found] ` <1750C725F99FA0C2.29160@groups.io>
2023-03-29 9:24 ` Guo, Gua [this message]
2023-03-28 17:31 ` [PATCH v2 04/13] BaseTools: Remove VS2008, 2010, 2012 and 2013 toolchain definitions Rebecca Cran
2023-03-28 17:31 ` [PATCH v2 05/13] BaseTools: Remove VS2008-VS2013 remnants Rebecca Cran
2023-03-28 17:31 ` [PATCH v2 06/13] MdePkg: " Rebecca Cran
2023-03-28 17:31 ` [PATCH v2 07/13] edksetup.bat: " Rebecca Cran
2023-03-28 17:31 ` [PATCH v2 08/13] BaseTools: Remove unused IPHONE_TOOLS and SOURCERY_CYGWIN_TOOLS defs Rebecca Cran
2023-03-28 17:31 ` [PATCH v2 09/13] BaseTools: Remove EBC (EFI Byte Code) compiler definitions Rebecca Cran
2023-03-28 17:31 ` [PATCH v2 10/13] OvmfPkg: Use Xcode5 version of CpuExceptionHandlerLib for CLANGDWARF Rebecca Cran
2023-03-28 17:31 ` [PATCH v2 11/13] Delete GCC48 and GCC49 toolchains and rename GCC5 to GCC Rebecca Cran
2023-03-28 17:31 ` [PATCH v2 12/13] BaseTools: Remove unused CYGWIN_ defines from tools_def.txt.template Rebecca Cran
2023-03-28 17:31 ` [PATCH v2 13/13] Bump tools_def.txt VERSION to 3.0 Rebecca Cran
2023-03-28 17:57 ` [PATCH v2 00/13] BaseTools,CryptoPkg,MdePkg,OvmfPkg: Delete CLANG35,CLANG38,GCC48,GCC49, rename GCC5 to GCC, update CLANGDWARF, delete VS 2008-2013, EBC Ard Biesheuvel
2023-03-28 18:01 ` Rebecca Cran
2023-03-28 18:12 ` [edk2-devel] " Ard Biesheuvel
2023-03-29 10:21 ` Rebecca Cran
2023-03-29 10:30 ` Ard Biesheuvel
2023-03-29 1:19 ` 回复: " gaoliming
2023-03-29 7:39 ` Ard Biesheuvel
2023-03-29 10:20 ` Rebecca Cran
2023-03-29 11:28 ` Leif Lindholm
2023-03-29 11:53 ` Ard Biesheuvel
2023-04-02 15:41 ` 回复: " Rebecca Cran
2023-04-02 16:36 ` Ard Biesheuvel
2023-04-02 16:42 ` Michael D Kinney
2023-04-02 18:38 ` Pedro Falcato
2023-04-02 21:50 ` Rebecca Cran
2023-04-03 11:30 ` Gerd Hoffmann
2023-04-03 11:33 ` Rebecca Cran
2023-04-03 11:39 ` Gerd Hoffmann
2023-04-03 11:55 ` Ard Biesheuvel
2023-04-03 12:15 ` Leif Lindholm
2023-04-03 12:26 ` Rebecca Cran
2023-04-03 13:44 ` Pedro Falcato
2023-04-03 13:54 ` Rebecca Cran
2023-04-03 14:08 ` Gerd Hoffmann
2023-04-03 14:27 ` Rebecca Cran
2023-04-03 19:42 ` Michael D Kinney
2023-04-03 19:54 ` Rebecca Cran
2023-04-03 20:23 ` Michael D Kinney
2023-04-03 13:04 ` Ard Biesheuvel
2023-04-03 13:27 ` Michael D Kinney
2023-04-03 13:43 ` Ard Biesheuvel
2023-04-04 1:31 ` 回复: " gaoliming
2023-04-04 15:49 ` Rebecca Cran
2023-04-04 15:57 ` Pedro Falcato
2023-04-04 16:32 ` Leif Lindholm
2023-04-04 17:00 ` Rebecca Cran
2023-04-04 17:45 ` Michael D Kinney
2023-04-04 17:48 ` Rebecca Cran
2023-04-04 17:52 ` Michael D Kinney
2023-04-04 17:57 ` Pedro Falcato
2023-04-04 18:03 ` Rebecca Cran
2023-04-04 18:26 ` Ard Biesheuvel
2023-04-04 18:29 ` Michael D Kinney
2023-04-04 18:36 ` Rebecca Cran
2023-04-05 10:21 ` Ard Biesheuvel
2023-04-06 0:57 ` 回复: " gaoliming
2023-04-06 2:49 ` Rebecca Cran
2023-04-06 7:32 ` Ard Biesheuvel
2023-04-06 9:19 ` Marcin Juszkiewicz
2023-03-29 12:20 ` Ard Biesheuvel
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-list from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=BL1PR11MB5478D93852428AF6EA0A3FD9EF899@BL1PR11MB5478.namprd11.prod.outlook.com \
--to=devel@edk2.groups.io \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox