mirror of
https://github.com/opnsense/src.git
synced 2026-05-28 04:12:45 -04:00
Fix ldscripts such that ld(1) collects the .fini_array section in the same
order as the .init_array section. Finalisation routines need to be called in the opposite order as their corresponding initialisation routines but rtld(1) handles that by calling the function pointers in .fini_array in reverse order. Reviewed by: kib MFC after: 2 weeks
This commit is contained in:
parent
8774c01832
commit
99e1a2bc3a
1 changed files with 1 additions and 1 deletions
|
|
@ -402,8 +402,8 @@ cat <<EOF
|
|||
.fini_array ${RELOCATING-0} :
|
||||
{
|
||||
${RELOCATING+${CREATE_SHLIB-PROVIDE_HIDDEN (${USER_LABEL_PREFIX}__fini_array_start = .);}}
|
||||
KEEP (*(.fini_array))
|
||||
KEEP (*(SORT(.fini_array.*)))
|
||||
KEEP (*(.fini_array))
|
||||
${RELOCATING+${CREATE_SHLIB-PROVIDE_HIDDEN (${USER_LABEL_PREFIX}__fini_array_end = .);}}
|
||||
}
|
||||
${SMALL_DATA_CTOR-${RELOCATING+${CTOR}}}
|
||||
|
|
|
|||
Loading…
Reference in a new issue