diff options
author | Michael Meissner <gnu@the-meissners.org> | 1995-03-16 22:22:39 +0000 |
---|---|---|
committer | Michael Meissner <gnu@the-meissners.org> | 1995-03-16 22:22:39 +0000 |
commit | 86d0248d410b735833a330c6d0741431e29708d2 (patch) | |
tree | 8b4b53f68564434be672a67570be5e845af59965 /ld/scripttempl | |
parent | 4350753eb976d7f67f31eeab1ba3c9256af57b46 (diff) | |
download | gdb-86d0248d410b735833a330c6d0741431e29708d2.zip gdb-86d0248d410b735833a330c6d0741431e29708d2.tar.gz gdb-86d0248d410b735833a330c6d0741431e29708d2.tar.bz2 |
Provide eabi C++ static constructor/destructor support.
Diffstat (limited to 'ld/scripttempl')
-rw-r--r-- | ld/scripttempl/elfppc.sc | 16 |
1 files changed, 13 insertions, 3 deletions
diff --git a/ld/scripttempl/elfppc.sc b/ld/scripttempl/elfppc.sc index 1f9537a..8a6b78d 100644 --- a/ld/scripttempl/elfppc.sc +++ b/ld/scripttempl/elfppc.sc @@ -99,15 +99,25 @@ SECTIONS } .data1 ${RELOCATING-0} : { *(.data1) } ${RELOCATING+${OTHER_READWRITE_SECTIONS}} - .ctors ${RELOCATING-0} : { *(.ctors) } - .dtors ${RELOCATING-0} : { *(.dtors) } ${RELOCATING+_GOT1_START_ = .;} .got1 ${RELOCATING-0} : { *(.got1) } ${RELOCATING+_GOT1_END_ = .;} + /* Put .ctors and .dtors next to the .got2 section, so that the pointers + get relocated with -mrelocatable. */ + ${RELOCATING+_GOT2_START_ = .;} - .got2 ${RELOCATING-0} : { *(.got2) } + .got2 ${RELOCATING-0} : { *(.got2) } + + ${RELOCATING+__CTOR_LIST__ = .;} + .ctors ${RELOCATING-0} : { *(.ctors) } + ${RELOCATING+__CTOR_END__ = .;} + + ${RELOCATING+__DTOR_LIST__ = .;} + .dtors ${RELOCATING-0} : { *(.dtors) } + ${RELOCATING+__DTOR_END__ = .;} + ${RELOCATING+_GOT2_END_ = .;} ${RELOCATING+_GOT_START_ = .;} |