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 driver/28718] Call to -lgcc added prior to user libraries


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28718

--- Comment #13 from Joerg Wunsch <j at uriah dot heep.sax.de> 2012-09-05 15:08:27 UTC ---
All this is fighting the symptoms though.

My point (as outlined in comment #8:
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28718#c8 )
is:

When operating as a C compiler, *all* user-supplied libraries are passed
to the linker *first*, followed by system libraries.

When operating as a C++ compiler, libstdc++ and libm.a are passed *before*
any user-supplied library.  This leaves the users in a situation where
they are no longer able to supply own overrides for some functions in
system libraries.  Again, all this is in contrast to how the C compiler
works.

In the AVR case, the situation is only worse since there's no libstdc++
(yet), and somehow, libgcc is substituted in place of libstdc++ (which I
think is a completely flawed idea from the beginning).

So despite all the artefacts which leaded to this bug report, I think at
least the last point mentioned is worth fixing: if there's no libstdc++,
there's no point in trying to pretend libgcc could be supplied as a
replacement for libstdc++.  (The AVR-related artefacts are now mostly
fixed after Johann's recent work, the original bug(s) remain(s).)


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