Duplicate Symbol

Vardhan, Sundara (GE Infra, Energy) sundara.vardhan@ge.com
Wed Feb 10 17:45:00 GMT 2010


Hi Ian

I forgot to mention that I had used AIX as and AIX ld when compiling the
gcc on AIX. Perhaps the as does not understand the hidden symbols that
are to be hidden. I plan to give a try with GNU as  and see it matters.
I think using GNU as on AIX causes some issues.
I will try that.

With Regards

Vardhan 

-----Original Message-----
From: Ian Lance Taylor [mailto:iant@google.com] 
Sent: Monday, February 08, 2010 7:25 PM
To: Vardhan, Sundara (GE Infra, Energy)
Cc: gcc-help@gcc.gnu.org
Subject: Re: Duplicate Symbol

"Vardhan, Sundara (GE Infra, Energy)" <sundara.vardhan@ge.com> writes:

> Compiling using GCC 4.4.3 and linking using AIX ld, I get some 
> duplicate symbol warnings. Upon debugging further I see that they are 
> defined in libgcc_s.a and also in libgcc.a.
> Should we have both of these library directories?

It is normal to have both, yes.  The situation on AIX is uncommon.
Normally linking against -lgcc_s and -lgcc is fine, and is done because
there are a few objects which are put in -lgcc but not in -lgcc_s.  I'm
not sure how this is supposed to work on AIX.

Ian



More information about the Gcc-help mailing list