[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Linking in C++ mode

From: Ralf Corsepius
Subject: Re: Linking in C++ mode
Date: 11 Nov 2002 05:37:30 +0100

Am Mon, 2002-11-11 um 00.50 schrieb Earnie Boyd:
> John Levon wrote:
> > On Sun, Nov 10, 2002 at 01:01:08PM +0100, Ralf Corsepius wrote:
> > 
> > 
> >>>You could always just add -lstdc++ to the oprofiled_LDADD variable.
> >>
> >>This would be a fault, IMO.
> > 
> Why?
Because linking c++ is more than adding -lstdc++.
> > I do not think getting gcc to link -lstdc++ is a good idea either, but
> > it doesn't have much more hack value than the solution you propose below
> > IMHO.
> > 
> It's the hack that using g++ performs.
... no. Using g++ for linking performs other g++-internal tasks, such as
composing ctors/dtors lists for static constructors and to pull in
further (g++-internal) libraries into linking (cf. collect2 in newer

What it exactly does is highly target- and gcc-version depending. It can
boil down to "just adding -lstdc++", but in most cases it will perform


reply via email to

[Prev in Thread] Current Thread [Next in Thread]