This is the mail archive of the
mailing list for the GCC project.
Re: multiple definitions of 'xxx keyed to...' in egcs-1.1.1
- To: law at cygnus dot com
- Subject: Re: multiple definitions of 'xxx keyed to...' in egcs-1.1.1
- From: Jason Merrill <jason at cygnus dot com>
- Date: 21 Feb 1999 16:15:59 -0800
- Cc: hjl at lucon dot org (H.J. Lu), egcs at egcs dot cygnus dot com, egcs-patches at egcs dot cygnus dot com
- References: <firstname.lastname@example.org>
>>>>> Jeffrey A Law <email@example.com> writes:
> In message <firstname.lastname@example.org>you write:
>> This is wrong, or at least incomplete. ASM_OUTPUT_CONSTRUCTOR does not
>> imply the use of .ctors/.dtors sections.
> Right. That's why trying to fix this problem by depending on that macro
> is wrong.
> It sounds like we need a new macro which indicates the target uses
> ctor/dtor sections and the dynamic linker handles firing of ctors/dtors.
> Given such a macro, we can safely make these functions static on those
> systems where it is safe.
I think ASM_OUTPUT_CONSTRUCTOR can be that macro, if we change the
documentation; it looks like the aoutos.h version was the only one that
would break with HJ's patch. All the definitions for COFF and such
targets looked fine; they also rely on the value of the symbol within the
translation unit rather than having it available to the linker. We only
need the symbols to be public if we're using collect.
Having another macro would also be fine, and would allow for runtime