This is the mail archive of the binutils@sourceware.cygnus.com mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Binutils 2.9.5.0.29 ld crash


On Fri, Mar 10, 2000 at 03:42:42PM -0800, Philippe Troin wrote:
> 
> It seems to be related with the debugging symbols, compiling without
> -g seems to works.

It may be a compiler bug. If you can provide a complete test, I
can look into it if I can reproduce it on Solaris 2.7/Sparc. binaries
files are ok.

> 
> Phil.
> 
> Philippe Troin <phil@aristotech.com> writes:
> 
> > [Note: I did not know which address was right, so I sent to both lucon
> > and valinux]

Both are ok.

> > 
> > I got a crash in GNU ld:
> >   GNU ld version 2.9.5 (with BFD 2.9.5.0.29)
> > on
> >   SunOS bigsun 5.5.1 Generic_103640-29 sun4u sparc
> > 
> > Binutils were compiled with:
> >   gcc version egcs-2.91.66 19990314 (egcs-1.1.2 release)
> > on the same machine.
> > 
> > Here's the message
> > 
> >    g++ -shared -Wl,-soname,stg.so,-Bsymbolic -o stg.so stg.o stgaristo.o
> >    stgfs.o stgio.o stgMf.o stgnt.o stgopen.o stgPtrPersistor.o
> >    stgstreamb.o stgtar.o -L/usr/openwin/lib
> >    -L/home/phil/work/build-cov/gandalf/lib
> >    -L/home/phil/work/build-cov/tpc/lib -lpthread -lm -lc -lstd7d -ltls15d
> >    -lbase -lmultifile
> >    
> >    stgstreamb.o: In function `stgStreamBufCL::setbuf(char *, int)':
> >    /home/phil/work/build-cov/gandalf_src/stg/src/stgstreamb.cpp:206:
> >      undefined reference to `no symbol'
> >    /home/phil/work/build-cov/tpc/bin/ld: BFD internal error, 
> >      aborting at elflink.h line 4958 in elf_link_output_extsym
> > 
> >    /home/phil/work/build-cov/tpc/bin/ld: Please report this bug.
> > 
> >    collect2: ld returned 1 exit status
> >    make: *** [stg.so] Error 1
> > 
> > The linked files were compiled with:
> > 
> >    g++ -MD -g -ftest-coverage -fprofile-arcs -Werror -nostdinc++
> >    -I/home/phil/work/build-cov/gandalf_src/stg/solaris
> >    -I/home/phil/work/build-cov/gandalf_src/stg/src
> >    -I/home/phil/work/build-cov/gandalf/include
> >    -I/home/phil/work/build-cov/tpc/include
> >    -I/home/phil/work/build-cov/tpc/include/g++ -I/usr/openwin/include
> >    -DGND_DEBUG -DRW_MULTI_THREAD -D_REENTRANT -mcpu=ultrasparc
> >    -mtune=ultrasparc -o stgtar.o -c
> >    /home/phil/work/build-cov/gandalf_src/stg/src/stgtar.cpp
> > 
> > /home/phil/work/build-cov/gandalf_src/stg/src/stgstreamb.cpp:206 is
> > 
> > 	   streambuf *stgStreamBufCL::setbuf(char *ptr, int len)
> > 	   {
> > 		   if (ebuf())
> > 			   return NULL;
> > 		   if ((!ptr) || (len <= 0))
> > 			   unbuffered(1);
> > 		   else {
> > 	   #ifdef GND_WIN32
> > 			   lock();
> > 	   #endif // GND_WIN32
> > 206---->		   setb(ptr, ptr+len, 0);
> > 	   #ifdef GND_WIN32
> > 			   unlock();
> > 	   #endif // GND_WIN32
> > 		   }
> > 		   return this;
> > 	   }
> > 
> > with:
> > 
> >    class stgStreamBufCL : public streambuf ....
> > 
> > streambuf comes from libstdc++ 2.9.0.
> > 
> > The nm output of stgstreamb.o says:
> > 
> > 	    U streambuf::setb(char *, char *, int)
> >    00000ec0 T stgStreamBufCL::setbuf(char *, int)      
> > 
> > If you need more info, feel free to email me.
> > 
> > Phil.

-- 
H.J. Lu (hjl@gnu.org)

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]