[Bug lto/68902] --as-needed consider library as unneeded even when library have __init functions

pinskia at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Mon Dec 14 22:39:00 GMT 2015


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

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|---                         |INVALID

--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Not a GCC bug.  This is the same behavior you get with archives (static
libraries) also.
Also GCC does not default to --as-needed; only the modified debian/ubuntu GCC
does.

Also --as-needed is a linker option and not a GCC option.  If you think this is
a linker bug (I don't think it is), then report it to binutils instead
(https://sourceware.org/bugzilla/).


More information about the Gcc-bugs mailing list