[Bug 872687] Re: c++ -flto always results in unresolved symbols
Bug Watch Updater
872687 at bugs.launchpad.net
Wed Oct 12 21:28:00 UTC 2011
Launchpad has imported 1 comments from the remote bug at
http://sourceware.org/bugzilla/show_bug.cgi?id=13287.
If you reply to an imported comment from within Launchpad, your comment
will be sent to the remote bug automatically. Read more about
Launchpad's inter-bugtracker facilities at
https://help.launchpad.net/InterBugTracking.
------------------------------------------------------------------------
On 2011-10-12T20:31:11+00:00 Matthias Klose wrote:
seen with the 2.22 branch (and the fix for pr13250 applied), works with
gold, gcc is 4.6 from the branch.
$ cat foo.cc
int main() {}
$ g++ -B/usr/lib/gold-ld/ -Wl,--as-needed -flto foo.cc
ok
$ $ gcc -Wl,--as-needed -flto foo.cc
ok
$ $ g++ -Wl,--as-needed -flto foo.cc
/lib/i386-linux-gnu/libc.so.6: undefined reference to `_dl_argv at GLIBC_PRIVATE'
/lib/i386-linux-gnu/libc.so.6: undefined reference to `__libc_stack_end at GLIBC_2.1'
/lib/i386-linux-gnu/libc.so.6: undefined reference to `__libc_enable_secure at GLIBC_PRIVATE'
/lib/i386-linux-gnu/libc.so.6: undefined reference to `_rtld_global at GLIBC_PRIVATE'
/lib/i386-linux-gnu/libc.so.6: undefined reference to `___tls_get_addr at GLIBC_2.3'
/lib/i386-linux-gnu/libc.so.6: undefined reference to `_rtld_global_ro at GLIBC_PRIVATE'
collect2: ld returned 1 exit status
Reply at: https://bugs.launchpad.net/binutils/+bug/872687/comments/1
** Changed in: binutils
Status: Unknown => Confirmed
** Changed in: binutils
Importance: Unknown => Medium
--
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to binutils in Ubuntu.
https://bugs.launchpad.net/bugs/872687
Title:
c++ -flto always results in unresolved symbols
Status in binutils:
Confirmed
Status in “binutils” package in Ubuntu:
Confirmed
Bug description:
=======main.cc =====
int main() {}
===================
c++ -flto main.cc
results in unresolved symbol errors on latest oneiric beta
Adding -static is a work around
To manage notifications about this bug go to:
https://bugs.launchpad.net/binutils/+bug/872687/+subscriptions
More information about the foundations-bugs
mailing list