From ba71b50bef042ed404759a8d48bef1f779cec6d6 Mon Sep 17 00:00:00 2001 From: Fabrice Fontaine Date: Tue, 16 Dec 2025 15:02:28 +0100 Subject: [PATCH] Makefile: unconditionally disable SSP Though -nostdlib is passed in $(CFLAGS), -fno-stack-protector must also be passed to avoid linking errors related to undefined references to '__stack_chk_guard' and '__stack_chk_fail' if toolchain enforces -fstack-protector. Fixes: - http://autobuild.buildroot.net/results/3a3a21f3c35ea025e9b93e09c2454aed0ad31034 Upstream: N/A Buildroot specific Signed-off-by: Fabrice Fontaine Signed-off-by: Kory Maincent --- Makefile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 3f27be4dff4f..52423507f50b 100644 --- a/Makefile +++ b/Makefile @@ -16,7 +16,8 @@ INCLUDES = $(SRCDIR)/include CFLAGS =-march=armv7-m -mcpu=cortex-m3 -mthumb -nostdlib -ffreestanding -Wall -Wundef \ -Werror-implicit-function-declaration -Wstrict-prototypes \ -Wdeclaration-after-statement -fno-delete-null-pointer-checks \ - -Wempty-body -fno-strict-overflow -g -I$(INCLUDES) -O2 -MD + -Wempty-body -fno-strict-overflow -fno-stack-protector \ + -g -I$(INCLUDES) -O2 -MD LDFLAGS =-nostartfiles -fno-exceptions -Tfirmware.ld EXECUTABLE=am335x-pm-firmware.elf -- 2.43.0