]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blobdiff - ld/scripttempl/elfxtensa.sc
bfd:
[thirdparty/binutils-gdb.git] / ld / scripttempl / elfxtensa.sc
index efeaa0260a3b0cf6a5647660ec798683ab48500a..29282aa04c09c913db2f792918c8cec931592985 100644 (file)
@@ -15,6 +15,7 @@
 #      OTHER_RELRO_SECTIONS - other than .data.rel.ro ...
 #              (e.g. PPC32 .fixup, .got[12])
 #      OTHER_BSS_SECTIONS - other than .bss .sbss ...
+#      ATTRS_SECTIONS - at the end
 #      OTHER_SECTIONS - at the end
 #      EXECUTABLE_SYMBOLS - symbols that must be defined for an
 #              executable (e.g., _DYNAMIC_LINK)
@@ -109,6 +110,7 @@ test -z "${ETEXT_NAME}" && ETEXT_NAME=etext
 test -n "$CREATE_SHLIB$CREATE_PIE" && test -n "$SHLIB_DATA_ADDR" && COMMONPAGESIZE=""
 test -z "$CREATE_SHLIB$CREATE_PIE" && test -n "$DATA_ADDR" && COMMONPAGESIZE=""
 test -n "$RELRO_NOW" && unset SEPARATE_GOTPLT
+test -z "$ATTRS_SECTIONS" && ATTRS_SECTIONS=".gnu.attributes 0 : { KEEP (*(.gnu.attributes)) }"
 DATA_SEGMENT_ALIGN="ALIGN(${SEGMENT_SIZE}) + (. & (${MAXPAGESIZE} - 1))"
 DATA_SEGMENT_RELRO_END=""
 DATA_SEGMENT_END=""
@@ -533,6 +535,7 @@ cat <<EOF
   ${TINY_BSS_SECTION}
 
   ${STACK_ADDR+${STACK}}
+  ${ATTRS_SECTIONS}
   ${OTHER_SECTIONS}
   ${RELOCATING+${OTHER_SYMBOLS}}
   ${RELOCATING+${STACKNOTE}}