[patch] Generalize stripping of shared library version in collect2

Mark Mitchell mark@codesourcery.com
Sun Dec 30 22:50:00 GMT 2007


John David Anglin wrote:
> This is another patch that deals with constructor naming.  We need
> to strip shared library version information when generating global
> constructors for shared objects to main a consistent library interface
> between library versions.

How does the name of the global constructor affect application linked
against the shared object?  I'm not doubting that it does, but would you
please walk me through it?

> This patch adds the capability to define an arbitrary shared library
> suffix.

Certainly the hard-coded ".so" in collect2 is a bad thing.  Messing
around with the filenames at all seems like a bit of a hack; there's
nothing that requires that shared object contain ".so" even on most
systems.  But, your patch certainly seems consistent with the way that
we're presently handling this.

Thanks,

-- 
Mark Mitchell
CodeSourcery
mark@codesourcery.com
(650) 331-3385 x713



More information about the Gcc-patches mailing list