From 9e9f81b75c1b44da149752f44dd240a5e316240e Mon Sep 17 00:00:00 2001 From: Imbus <> Date: Thu, 28 Mar 2024 11:25:58 +0100 Subject: [PATCH] Discard section for .note, .note.* and other commonly discarded sections --- ch32v003fun/ch32v003fun.ld | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/ch32v003fun/ch32v003fun.ld b/ch32v003fun/ch32v003fun.ld index 982bd85..4ad76b4 100644 --- a/ch32v003fun/ch32v003fun.ld +++ b/ch32v003fun/ch32v003fun.ld @@ -178,6 +178,14 @@ SECTIONS PROVIDE( end = . ); PROVIDE( _eusrstack = ORIGIN(RAM) + LENGTH(RAM)); + + /DISCARD/ : { + *(.note .note.*) + *(.eh_frame .eh_frame.*) + *(.comment .comment.*) + *(.ARM.extab* .gnu.linkonce.armextab.*) + *(.ARM.exidx*) + } } -- GitLab