This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: Bug report: objc classes linked in wrong order
- To: nicola at brainstorm dot co dot uk
- Subject: Re: Bug report: objc classes linked in wrong order
- From: Jeffrey A Law <law at cygnus dot com>
- Date: Mon, 29 May 2000 11:42:06 -0600
- cc: rth at cygnus dot com, hjl at lucon dot org, egcs at sourceware dot cygnus dot com, ovidiu at cup dot hp dot com, gcc at gcc dot gnu dot org
- Reply-To: law at cygnus dot com
In message <Pine.LNX.4.10.10005261722570.26308-100000@lin9.brainstorm.co.uk>y
ou write:
>
> > > Anybody has any other idea about of how to have the NXConstantString cl
> ass
> > > from a shared library to be linked instead of the NXConstantString from
> a
> > > shared libobjc when linking both libraries ?
> >
> > Make the non-preferred one weak.
>
> Can I make an objective-C class weak ?
I can't think of a reason why that wouldn't work.
> I found no evidence of this - because each module has a list of classes to
> load, and loads them all - but I might be wrong - so please give me a hint
> if I actually can in some way make a class weak.
But they are "loaded" by the linker by including them in the final
executable, right? If so, at the .s/.o level you make the appropriate
function(s) weak, then you should be OK.
jeff
>