From 062739d1510d8ed2c1558dcd51cf958ce52855c3 Mon Sep 17 00:00:00 2001 From: Nick Clifton Date: Wed, 12 Jul 2000 16:41:29 +0000 Subject: Support the g++ attribute init_priority in gcc 2.95.2 and later. --- ld/ChangeLog | 5 +++++ ld/scripttempl/i386go32.sc | 12 ++++++++++-- 2 files changed, 15 insertions(+), 2 deletions(-) diff --git a/ld/ChangeLog b/ld/ChangeLog index 7826d93..8d3e757 100644 --- a/ld/ChangeLog +++ b/ld/ChangeLog @@ -1,3 +1,8 @@ +2000-07-12 Mark Elbrecht + + * scripttempl/i386go32.sc: Support the g++ attribute init_priority in + gcc 2.95.2 and later. + 2000-07-11 Kazu Hirata * ldfile.c (ldfile_try_open_bfd): Output '\n' after an error diff --git a/ld/scripttempl/i386go32.sc b/ld/scripttempl/i386go32.sc index f14aff7..330e4d3 100644 --- a/ld/scripttempl/i386go32.sc +++ b/ld/scripttempl/i386go32.sc @@ -5,8 +5,14 @@ EXE=${CONSTRUCTING+${RELOCATING+-exe}} # These are substituted in as variables in order to get '}' in a shell # conditional expansion. -CTOR='.ctor : { *(.ctor) }' -DTOR='.dtor : { *(.dtor) }' +CTOR='.ctor : { + *(SORT(.ctors.*)) + *(.ctor) + }' +DTOR='.dtor : { + *(SORT(.dtors.*)) + *(.dtor) + }' cat <