summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPatrick Georgi <pgeorgi@google.com>2021-07-19 19:09:05 +0200
committerPatrick Georgi <pgeorgi@google.com>2021-09-19 18:52:22 +0000
commit1c8e8b259d18b3692811243ca7e4b95ade2a8095 (patch)
tree46987d55547d5e11c40acf9e5be9b68bec663c73
parentf28e368d583b0ee1b5297f4d4d0288a1b38f06e0 (diff)
downloadcoreboot-1c8e8b259d18b3692811243ca7e4b95ade2a8095.tar.gz
arch/riscv: Avoid gcc11 replacing memset implementation with memset call
SBI comes with its own memset implementation (under a slightly different name) that gcc11 "helpfully" tries to replace with a call to memset(). Since we don't provide a memset, the linker isn't happy, so prevent gcc from doing that. Change-Id: I3459a519d46a123f873306000b8b2261bd64e0c3 Signed-off-by: Patrick Georgi <pgeorgi@google.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/56429 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Nico Huber <nico.h@gmx.de> Reviewed-by: Angel Pons <th3fanbus@gmail.com>
-rw-r--r--src/arch/riscv/Makefile.inc2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/arch/riscv/Makefile.inc b/src/arch/riscv/Makefile.inc
index cd94692c02..272768d025 100644
--- a/src/arch/riscv/Makefile.inc
+++ b/src/arch/riscv/Makefile.inc
@@ -171,7 +171,7 @@ $(OPENSBI_TARGET): $(obj)/config.h | $(OPENSBI_SOURCE)
mkdir -p $(OPENSBI_BUILD)
$(MAKE) \
-C "$(OPENSBI_SOURCE)" \
- CC="$(CC_ramstage)" \
+ CC="$(CC_ramstage) -fno-builtin" \
LD="$(LD_ramstage)" \
OBJCOPY="$(OBJCOPY_ramstage)" \
AR="$(AR_ramstage)" \