soc/sensry: Discard .note.GNU-stack sections while linking

These sections are simple stack behavior annotations and are not
needed in the final executable.

Signed-off-by: Keith Packard <keithp@keithp.com>
This commit is contained in:
Keith Packard 2025-06-05 09:06:53 -07:00 committed by Henrik Brix Andersen
commit ce7bd57618

View file

@ -240,6 +240,8 @@ SECTIONS
#include <zephyr/linker/debug-sections.ld> #include <zephyr/linker/debug-sections.ld>
/DISCARD/ : { *(.note.GNU-stack) }
SECTION_PROLOGUE(.riscv.attributes, 0,) SECTION_PROLOGUE(.riscv.attributes, 0,)
{ {
KEEP(*(.riscv.attributes)) KEEP(*(.riscv.attributes))