From 888a61bd085d8b031c1b05b22eae51fae1004aba Mon Sep 17 00:00:00 2001 From: Havard Skinnemoen Date: Wed, 24 Jun 2020 23:34:27 -0700 Subject: Fix build with gcc-9 arm-linux-gnueabi toolchain Linux toolchains link dynamically by default, so pass -static. gcc also adds a .note.gnu.build-id to the beginning of the file, which messes up our reset vector when converting to a raw binary file. Passing --build-id=none to the linker gets rid of it. Change-Id: If64eb0fe7298480d5a9c04730088d74b32bcb082 --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index b7f705c..3b2b2f3 100644 --- a/Makefile +++ b/Makefile @@ -20,7 +20,7 @@ OBJCOPY = $(CROSS_COMPILE)objcopy CFLAGS = -Os -g -mcpu=cortex-a9 ASFLAGS = $(CFLAGS) -Wa,-mcpu=cortex-a9+mp LDSCRIPT = bootrom.ld -LDFLAGS = -nostdlib -T $(LDSCRIPT) +LDFLAGS = -Wl,--build-id=none -static -nostdlib -T $(LDSCRIPT) OBJS := start.o image.o -- cgit v1.1