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

Bug#578831: marked as done (link failure with LTO: “invalid DSO for symbol `pthread_cancel@@GLIBC_2.0' definition”)



Your message dated Sat, 07 Aug 2010 21:46:31 +0200
with message-id <4C5DB817.40307@debian.org>
and subject line Re: Bug#578831: link failure with LTO: “invalid DSO for symbol `pthread_cancel@@GLIBC_2.0' definition”
has caused the Debian Bug report #578831,
regarding link failure with LTO: “invalid DSO for symbol `pthread_cancel@@GLIBC_2.0' definition”
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact owner@bugs.debian.org
immediately.)


-- 
578831: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=578831
Debian Bug Tracking System
Contact owner@bugs.debian.org with problems
--- Begin Message ---
Severity: normal
Package: gcc-4.5
Version: 4.5.0-1

Hi,

I'm trying to link a project with g++-4.5 and LTO:

 $ g++-4.5 -flto -fno-exceptions -Wl,--gc-sections -lGL -lGLU  -L/usr/X11R6/lib -lXext -lX11 -lfreetype -lz -o parser script/parser.o common/common.a texgen/texgen.a meshgen/meshgen.a texgen/texturescript.o meshgen/meshscript.o
  /usr/bin/ld: Ñ: invalid DSO for symbol `pthread_cancel@@GLIBC_2.0' definition
  /lib/libpthread.so.0: could not read symbols: Bad value
  collect2: ld returned 1 exit status

It works with no errors if I remove -flto. (There's lots of other chaos if I
throw -frepo into the mix, but I'll keep that for a later bug. :-) )

Unfortunately these sources are private, so I cannot post them to the bug.
I'd be happy providing a tarball to the GCC Debian maintainers or upstream,
though, provided that they are not made public.

/* Steinar */
-- 
Chief, Tech:Server
http://www.sesse.net/



--- End Message ---
--- Begin Message ---
fixed in binutils 2.20.1-13 (and in binutils from experimental).

On 22.06.2010 19:43, Steinar H. Gunderson wrote:
On Tue, Jun 22, 2010 at 02:53:24PM +0200, Matthias Klose wrote:
please recheck with the current g++-4.5 in experimental.  -lpthread
shouldn't be used directly, but pass -pthread to both CXXFLAGS and
LDFLAGS.

Pretty much no change. With CXXFLAGS including -pthread and LDFLAGS including
-pthread -flto -fwhole-program:

   script/script.a(curve.o): In function `_ZN6script5Curve13make_tangentsEv':
   curve.cpp:(.text._ZN6script5Curve13make_tangentsEv+0x3f2): undefined reference to `_ZN6script6engine13get_num_paramENS_5Curve8knottypeE'
   script/script.a(curve.o): In function `_ZN6script5Curve9get_valueEfPf':
   curve.cpp:(.text._ZN6script5Curve9get_valueEfPf+0x226): undefined reference to `_ZN6script6engine7targetsE'
   curve.cpp:(.text._ZN6script5Curve9get_valueEfPf+0x236): undefined reference to `_ZN6script6engine8texturesE'
   curve.cpp:(.text._ZN6script5Curve9get_valueEfPf+0x262): undefined reference to `_ZN6script6engine6meshesE'
   curve.cpp:(.text._ZN6script5Curve9get_valueEfPf+0x28b): undefined reference to `_ZN6script6engine9materialsE'
   curve.cpp:(.text._ZN6script5Curve9get_valueEfPf+0x2a1): undefined reference to `_ZN6script6engine13get_num_paramENS_5Curve8knottypeE'
   collect2: ld returned 1 exit status
   make: *** [intro] Error 1

Without -fwhole-program in LDFLAGS it links, as before. With -frepo in the mix,
it's chaos as usual, with tons and tons of messages like

   script/parser.o: In function `_ZNSt8_Rb_treeISsSt4pairIKSsN6script6parser4meshEESt10_Select1stIS5_ESt4lessISsESaIS5_EE4findERS1_.clone.30': parser.cpp:(.text._ZNSt8_Rb_treeISsSt4pairIKSsN6script6parser4meshEESt10_Select1stIS5_ESt4lessISsESaIS5_EE4findERS1_.clone.30+0x38): undefined reference to `bool std::operator<  <char, std::char_traits<char>, std::allocator<char>  >(std::basic_string<char, std::char_traits<char>, std::allocator<char>  >  const&, std::basic_string<char, std::char_traits<char>, std::allocator<char>  >  const&)'

and other mising templates.

/* Steinar */



--- End Message ---

Reply to: