diff options
Diffstat (limited to 'ld/scripttempl/elf.sc')
-rw-r--r-- | ld/scripttempl/elf.sc | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/ld/scripttempl/elf.sc b/ld/scripttempl/elf.sc index be8d19f..5eadc18 100644 --- a/ld/scripttempl/elf.sc +++ b/ld/scripttempl/elf.sc @@ -244,7 +244,7 @@ RELA_IPLT=".rela.iplt ${RELOCATING-0} : DYNAMIC=".dynamic ${RELOCATING-0} : { *(.dynamic) }" RODATA=".${RODATA_NAME} ${RELOCATING-0} : { *(.${RODATA_NAME}${RELOCATING+ .${RODATA_NAME}.* .gnu.linkonce.r.*}) }" DATARELRO=".data.rel.ro : { *(.data.rel.ro.local* .gnu.linkonce.d.rel.ro.local.*) *(.data.rel.ro .data.rel.ro.* .gnu.linkonce.d.rel.ro.*) }" -DISCARDED="/DISCARD/ : { *(.note.GNU-stack) *(.gnu_debuglink) *(.gnu.lto_*) *(.gnu_object_only) }" +DISCARDED="/DISCARD/ : { *(.note.GNU-stack) *(.gnu_debuglink) *(.gnu.lto_*) *(.gnu_object_only) *(.gnu.mutable) }" if test -z "${NO_SMALL_DATA}"; then SBSS=".${SBSS_NAME} ${RELOCATING-0} : { @@ -855,6 +855,12 @@ cat <<EOF ${DATA_SDATA-${SDATA}} ${DATA_SDATA-${OTHER_SDATA_SECTIONS}} + .gnu.mutable ${RELOCATING-0} : ${RELOCATING+ALIGN(${MAXPAGESIZE})} + { + *(.gnu.mutable) + . = ALIGN(. != 0 ? CONSTANT (MAXPAGESIZE): 1); + } + ${RELOCATING+${SYMBOL_ABI_ALIGNMENT+. = ALIGN(${SYMBOL_ABI_ALIGNMENT});}} ${RELOCATING+${DATA_END_SYMBOLS-${CREATE_SHLIB+PROVIDE (}$(def_symbol "_edata")${CREATE_SHLIB+)}; PROVIDE ($(def_symbol "edata"));}} |