Problem of execution order of entries in .fini_array

Hans-Peter Nilsson hans-peter.nilsson@axis.com
Thu Apr 16 16:21:00 GMT 2009


> Received-SPF: none (bart: domain of newlib-return-7494-hp=axis.com@sourceware.org does not designate permitted sender hosts) client ip=209.132.176.174; envelope-from=newlib-return-7494-hp=axis.com@sourceware.org; helo=sourceware.org;
> X-SWARE-Spam-Status: No, hits=-0.4 required=5.0 	tests=AWL,BAYES_00,SARE_MSGID_LONG40,SPF_PASS
> X-Spam-Check-By: sourceware.org
> MIME-Version: 1.0
> Date: Wed, 15 Apr 2009 16:08:17 -0700
> From: Jing Yu <jingyu@google.com>

(Long analysis cut short)
> Should we change the access order or fini_array?

I'd suggest correcting the access order, as opposed to hacking
the linker.  See for example glibc.

(Note that there are *three* files in newlib doing the access in
the wrong order.  And I'm not counting the misguided
newlib/libc/sys/arm/crt0.S in which fini_array is treated like a
synonym for _fini!)

brgds, H-P



More information about the Newlib mailing list