From: Alan Modra Date: Fri, 7 Jul 2023 04:03:56 +0000 (+0930) Subject: Re: Align linkerscript symbols according to ABI X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=9596ca8194b0b829f7392f5da773026b7aa293fd;p=binutils-gdb.git Re: Align linkerscript symbols according to ABI Align dot before symbols defined outside of output sections. Before _end is already aligned. * scripttempl/elf.sc (def_symbol): Tidy excess space. (_edata): Align before emitting symbol when SYMBOL_ABI_ALIGNMENT. --- diff --git a/ld/scripttempl/elf.sc b/ld/scripttempl/elf.sc index 9e95e6b4162..bfd8b5ed4b3 100644 --- a/ld/scripttempl/elf.sc +++ b/ld/scripttempl/elf.sc @@ -171,7 +171,7 @@ fi def_symbol() { if [ -z "${SYMBOL_ABI_ALIGNMENT}" ]; then - echo "${USER_LABEL_PREFIX}$1 = . " + echo "${USER_LABEL_PREFIX}$1 = ." else echo "${USER_LABEL_PREFIX}$1 = ALIGN(${SYMBOL_ABI_ALIGNMENT})" fi @@ -688,6 +688,7 @@ cat <