This is the mail archive of the gcc-bugs@gcc.gnu.org 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]

[Bug c++/17480] collect2 on AIX calls static constructors of unreferenced object modules


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=17480

LÅrinczy Zsigmond <lzsiga at axelero dot hu> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |lzsiga at axelero dot hu

--- Comment #5 from LÅrinczy Zsigmond <lzsiga at axelero dot hu> ---
This bug is still present in 4.6.4, it prevented me from building mysql-5.5.38:
collect2 decided to include constructors from elements of a '*.a' archive that
were not required by the current executable to link -- and in the second
link-pass the unresolved externals of these 'parasite' objects stopped the
linking with error.

Before finding this bug, I've documented this problem here:
http://www.linuxquestions.org/questions/aix-43/overly-zealous-collect2-on-aix-4175519409/

I think collect2 should do what its documentation says it should do: examine
the result of the first linking, and collect the constructors/destructors from
the objects 'ld' actually linked in.

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