This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug driver/42690] Undefined reference errors with -flto -fuse-linker-plugin
- From: "davek at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Tue, 23 Nov 2010 19:09:51 +0000
- Subject: [Bug driver/42690] Undefined reference errors with -flto -fuse-linker-plugin
- Auto-submitted: auto-generated
- References: <bug-42690-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42690
--- Comment #27 from Dave Korn <davek at gcc dot gnu.org> 2010-11-23 19:08:45 UTC ---
(In reply to comment #25)
> The current linker plugin scheme may be flawed. The order of
> linking libraries (archive and DSO) is very important. They
> have to be placed between crti.o and crtn.o. We may not link
> an archive after crtn.o.
Sounds like crtn.o should be sent to the link via a further -pass-through
option (positioned after the ones that re-scan the libraries) rather than
directly on the command-line when the plugin is in use.