comparison packages/hal/synth/arch/current/src/synth.ld @ 3291:68c8985fd5f0

* src/synth.ld src/synth_entry.c: Look for static constructors in the .init_array section as well as .ctors (needed for gcc 4.7 and later)
author jlarmour
date Fri, 03 Oct 2014 15:13:21 +0000
parents c23173de14a8
children
comparison
equal deleted inserted replaced
3290:a1df75458e13 3291:68c8985fd5f0
195 /* the pointers get relocated with -mrelocatable. */ \ 195 /* the pointers get relocated with -mrelocatable. */ \
196 . = ALIGN(8); __CTOR_LIST__ = ABSOLUTE(.); \ 196 . = ALIGN(8); __CTOR_LIST__ = ABSOLUTE(.); \
197 KEEP(*(SORT(.ctors*))) __CTOR_END__ = ABSOLUTE(.); \ 197 KEEP(*(SORT(.ctors*))) __CTOR_END__ = ABSOLUTE(.); \
198 __DTOR_LIST__ = ABSOLUTE(.); \ 198 __DTOR_LIST__ = ABSOLUTE(.); \
199 KEEP(*(SORT(.dtors*))) __DTOR_END__ = ABSOLUTE(.); \ 199 KEEP(*(SORT(.dtors*))) __DTOR_END__ = ABSOLUTE(.); \
200 /* In gcc 4.7, constructors moved from .ctors to .init_array . */ \
201 . = ALIGN(8); __init_array_start__ = ABSOLUTE(.); \
202 KEEP(*(SORT(.init_array*))) __init_array_end__ = ABSOLUTE(.); \
200 . = ALIGN(32); \ 203 . = ALIGN(32); \
201 KEEP(*( SORT (.ecos.table.*))); \ 204 KEEP(*( SORT (.ecos.table.*))); \
202 _GOT2_START_ = ABSOLUTE(.); *(.got2) _GOT2_END_ = ABSOLUTE(.); \ 205 _GOT2_START_ = ABSOLUTE(.); *(.got2) _GOT2_END_ = ABSOLUTE(.); \
203 _GOT_START_ = ABSOLUTE(.); _GLOBAL_OFFSET_TABLE_ = ABSOLUTE(. + 32768); \ 206 _GOT_START_ = ABSOLUTE(.); _GLOBAL_OFFSET_TABLE_ = ABSOLUTE(. + 32768); \
204 _SDA_BASE_ = ABSOLUTE(.); *(.got.plt) *(.got) \ 207 _SDA_BASE_ = ABSOLUTE(.); *(.got.plt) *(.got) \