This is the mail archive of the mailing list for the GCC project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [patch][RFC] Filename based shared library versioning on AIX

On 11/05/2012 07:31 PM, David Edelsohn wrote:
> On Mon, Nov 5, 2012 at 1:10 PM, Michael Haubenwallner
> <> wrote:
>> Well, as long as the old sharedlibs were not created as standalone shared
>> objects (, this is similar to a normal "soname"-bump on AIX, in that
>> it is still possible for the package manager to transfer the old shared
>> objects (with F_LOADONLY flag set) into the new archives.
> Yes, the old shared objects can be placed in the new archive, but one
> also needs to ensure that the archive has the correct name, e.g.
> libfoo.a not ad

Actually, AIX does symlink some of its system libraries (including libc), so
it seems to be fine when libfoo.a is a symlink to containing
the correct shared objects.

>> As far as I can see, gcc does not provide this libtool-option (environment
>> variable LDFLAGS=-brtl) at all for its libraries (for good reason).
> I do not understand what you mean by gcc does not provide this libtool
> option.  GCC does link libstdc++ with -G option, for use with -brtl,
> but does not automatically link applications with -brtl.

When vanilla libtool detects "-brtl" in LDFLAGS, it does:
  * Link the Shared Object with -G flag.
  * The Shared Object's filename is
  * Create symlink ->
  * Create symlink ->
  * Create libNAME.a from static objects.

When "-brtl" is not in LDFLAGS, it does it the traditional way:
  * Link the Shared Object with -bM:SRE flag.
  * The Shared Object's filename is
  * Put the Shared Object into libNAME.a

The former is what is incompatible with this "aix-soname" proposal, but I've never
seen any gcc library (libstdc++) being created that way as standalone Shared Object.

Instead, libstdc++ is created the traditional way, but with -G flag - not
listening to -brtl in LDFLAGS as vanilla libtool does.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]