[binutils-gdb] AVR: PR17107 - Add more .gnu.linkonce to avr.sc
Georg-Johann Lay
gjl@sourceware.org
Tue Jun 23 12:27:23 GMT 2026
https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=857d54be69c5da3737dd9c50c6c9f36ed9a14754
commit 857d54be69c5da3737dd9c50c6c9f36ed9a14754
Author: Georg-Johann Lay <avr@gjlay.de>
Date: Tue Jun 23 14:02:21 2026 +0200
AVR: PR17107 - Add more .gnu.linkonce to avr.sc
This patch adds pattern rules for .gnu.linkonce.t* and .gnu.linkone.b*
to the .text resp. .bss output sections. Though that's probably
not needed any more since G++ is using COMDAT today.
.gnu.linkonce.d* for .data and .gnu.linkone.r* for .rodata are
already there.
PR ld/17107
ld/
* scripttempl/avr.sc (.bss) [RELOCATING]: Add *(.gnu.linkonce.b*).
(.text) [RELOCATING]: Add *(.gnu.linkonce.t*).
Diff:
---
ld/scripttempl/avr.sc | 3 +++
1 file changed, 3 insertions(+)
diff --git a/ld/scripttempl/avr.sc b/ld/scripttempl/avr.sc
index e1c3a4bcee7..b3cf421a78b 100644
--- a/ld/scripttempl/avr.sc
+++ b/ld/scripttempl/avr.sc
@@ -271,6 +271,8 @@ cat <<EOF
*(.fini0) /* Infinite loop after program termination. */
KEEP (*(.fini0))
+ *(.gnu.linkonce.t*)
+
/* For code that needs not to reside in the lower progmem. */
*(.hightext)
*(.hightext*)
@@ -336,6 +338,7 @@ cat <<EOF
${RELOCATING+ PROVIDE (__bss_start = .) ; }
*(.bss)
${RELOCATING+ *(.bss*)}
+ ${RELOCATING+ *(.gnu.linkonce.b*)}
${RELOCATING+ *(COMMON)}
${RELOCATING+ PROVIDE (__bss_end = .) ; }
} ${RELOCATING+ > data}
More information about the Binutils-cvs
mailing list