All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v2] sbsa-acs,edk2-firmware: Adjust target tuple for clang
@ 2021-06-12  4:58 Khem Raj
  0 siblings, 0 replies; only message in thread
From: Khem Raj @ 2021-06-12  4:58 UTC (permalink / raw)
  To: meta-arm; +Cc: Khem Raj, Jon Mason, Ross Burton

Current settings assume glibc tuples and hence when building with musl C
library clang can not find correct cross tools and system headers and
libraries, really we should be using exact tuple that is in play so
using HOST_SYS is right replacement for OE

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Cc: Jon Mason <jon.mason@arm.com>
Cc: Ross Burton <ross.burton@arm.com>
---
v2: Move the patch to edk2-firmware and use HOST_SYS

 meta-arm/recipes-bsp/uefi/edk2-firmware.inc | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/meta-arm/recipes-bsp/uefi/edk2-firmware.inc b/meta-arm/recipes-bsp/uefi/edk2-firmware.inc
index c2d9bf1..2334201 100644
--- a/meta-arm/recipes-bsp/uefi/edk2-firmware.inc
+++ b/meta-arm/recipes-bsp/uefi/edk2-firmware.inc
@@ -64,6 +64,10 @@ export BTOOLS_PATH = "${EDK_TOOLS_PATH}/BinWrappers/PosixLike"
 EDK_COMPILER ?= "GCC5"
 EDK_COMPILER_toolchain-clang = "CLANG38"
 
+do_configure_prepend() {
+    sed -i -e "s#-target ${HOST_ARCH}-linux-gnu*#-target ${HOST_SYS}#" ${S}/BaseTools/Conf/tools_def.template
+}
+
 do_compile() {
     sed -i -e 's:-I \.\.:-I \.\. ${BUILD_CFLAGS} :' ${EDK_TOOLS_PATH}/Source/C/Makefiles/header.makefile
     sed -i -e 's: -luuid: -luuid ${BUILD_LDFLAGS}:g' ${EDK_TOOLS_PATH}/Source/C/*/GNUmakefile
-- 
2.32.0


^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2021-06-12  4:58 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-06-12  4:58 [PATCH v2] sbsa-acs,edk2-firmware: Adjust target tuple for clang Khem Raj

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.