bug-binutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug ld/13287] New: g++ -Wl,--as-needed -flto doesn't work with the BFD


From: doko at debian dot org
Subject: [Bug ld/13287] New: g++ -Wl,--as-needed -flto doesn't work with the BFD linker, but with gold
Date: Wed, 12 Oct 2011 20:31:11 +0000

http://sourceware.org/bugzilla/show_bug.cgi?id=13287

             Bug #: 13287
           Summary: g++ -Wl,--as-needed -flto doesn't work with the BFD
                    linker, but with gold
           Product: binutils
           Version: 2.22
            Status: NEW
          Severity: normal
          Priority: P2
         Component: ld
        AssignedTo: address@hidden
        ReportedBy: address@hidden
    Classification: Unclassified


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 address@hidden'
/lib/i386-linux-gnu/libc.so.6: undefined reference to
address@hidden'
/lib/i386-linux-gnu/libc.so.6: undefined reference to
address@hidden'
/lib/i386-linux-gnu/libc.so.6: undefined reference to
address@hidden'
/lib/i386-linux-gnu/libc.so.6: undefined reference to
address@hidden'
/lib/i386-linux-gnu/libc.so.6: undefined reference to
address@hidden'
collect2: ld returned 1 exit status

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]