public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "espindola at gcc dot gnu dot org" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug lto/42690] Undefined reference errors with -flto -fuse-linker-plugin Date: Fri, 15 Jan 2010 03:55:00 -0000 [thread overview] Message-ID: <20100115035453.31986.qmail@sourceware.org> (raw) In-Reply-To: <bug-42690-16926@http.gcc.gnu.org/bugzilla/> ------- Comment #5 from espindola at gcc dot gnu dot org 2010-01-15 03:54 ------- Note that -plugin-opt=-pass-through=/foo/bar/libgcc.a is missing in the linker invocation. That is the problem. When BUG is not defined, the undefined reference is visible early on. You can check that with GNUTARGET=plugin nm --prugin ..../libltoplugin.so foo.o If BUG is defined the plugin will not see a call since it will only created by codegen. That is why the driver asks the linker to take a second look at some libraries by passing the pass-through option. We have to figure out a better way to detected in gcc.c that libgcc (and/or libc) will be linked statically. H.J.Lu: You are probably linking with a shared libgcc, no? -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42690
next prev parent reply other threads:[~2010-01-15 3:55 UTC|newest] Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top 2010-01-11 15:23 [Bug lto/42690] New: " d dot g dot gorbachev at gmail dot com 2010-01-11 15:25 ` [Bug lto/42690] " d dot g dot gorbachev at gmail dot com 2010-01-12 16:30 ` espindola at gcc dot gnu dot org 2010-01-14 22:15 ` d dot g dot gorbachev at gmail dot com 2010-01-15 3:41 ` hjl dot tools at gmail dot com 2010-01-15 3:55 ` espindola at gcc dot gnu dot org [this message] 2010-01-15 4:26 ` hjl dot tools at gmail dot com 2010-01-15 11:02 ` d dot g dot gorbachev at gmail dot com 2010-01-15 11:02 ` d dot g dot gorbachev at gmail dot com 2010-01-15 11:02 ` d dot g dot gorbachev at gmail dot com 2010-01-15 11:03 ` d dot g dot gorbachev at gmail dot com 2010-01-15 11:04 ` [Bug driver/42690] " d dot g dot gorbachev at gmail dot com 2010-01-15 15:29 ` espindola at gcc dot gnu dot org 2010-01-16 16:56 ` d dot g dot gorbachev at gmail dot com 2010-01-17 5:47 ` espindola at gcc dot gnu dot org 2010-01-18 18:48 ` d dot g dot gorbachev at gmail dot com
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20100115035453.31986.qmail@sourceware.org \ --to=gcc-bugzilla@gcc.gnu.org \ --cc=gcc-bugs@gcc.gnu.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).