1
0
mirror of https://git.yoctoproject.org/poky synced 2026-06-04 14:09:47 +00:00

gnu-efi: Do not use gcc-only options when building with clang

(From OE-Core rev: 385126d1f1cc6af5882b9a926295f4f54e657613)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
Khem Raj
2019-10-06 18:40:12 -07:00
committed by Richard Purdie
parent f937d49ab3
commit 81544697fe
2 changed files with 25 additions and 0 deletions
@@ -0,0 +1,24 @@
Fix building with CLANG-9.0.0
Fixes
clang-9: error: unknown argument: '-maccumulate-outgoing-args'
Upstream-Status: Submitted [https://sourceforge.net/p/gnu-efi/patches/70/]
Signed-off-by: Khem Raj <raj.khem@gmail.com>
--- a/Make.defaults
+++ b/Make.defaults
@@ -110,10 +110,10 @@
|| ( [ $(GCCVERSION) -eq "4" ] \
&& [ $(GCCMINOR) -ge "7" ] ) ) \
&& echo 1)
- ifeq ($(GCCNEWENOUGH),1)
- CPPFLAGS += -DGNU_EFI_USE_MS_ABI -maccumulate-outgoing-args --std=c11
- else ifeq ($(USING_CLANG),clang)
+ ifeq ($(USING_CLANG),clang)
CPPFLAGS += -DGNU_EFI_USE_MS_ABI --std=c11
+ else ifeq ($(GCCNEWENOUGH),1)
+ CPPFLAGS += -DGNU_EFI_USE_MS_ABI -maccumulate-outgoing-args --std=c11
endif
CFLAGS += -mno-red-zone
@@ -15,6 +15,7 @@ LIC_FILES_CHKSUM = "file://gnuefi/crt0-efi-arm.S;beginline=4;endline=16;md5=e582
SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/${BP}.tar.bz2 \
file://parallel-make-archives.patch \
file://lib-Makefile-fix-parallel-issue.patch \
file://gnu-efi-3.0.9-fix-clang-build.patch \
"
SRC_URI[md5sum] = "32af17b917545a693e549af2439c4a99"