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 06:15:05PM -0800, Philippe Troin wrote:
> > 
> > Did you compile the .o files with -fpic or -fPIC? It looks like you
> > didn't. At least, I didn't find the symbol, _GLOBAL_OFFSET_TABLE_,
> > in those .o files. The GNU ld doesn't like -Bsymbolic without PIC.
> > We just fixed one similar bug. I guess it is another one.
> 
> No, I did not compile PIC code. PIC and code coverage are incompatible
> (on Solaris). So I compiled everything non-PIC, but sill in shared
> libraries.
> 
> AFAIK, it ought to be ok, except the libraries will no be shared
> accross processes, right ?
> 
> FYI, Sun ld refuses to link non-PIC in a shared lib. That's one of the
> reasons why we're using GNU ld.
> 

As you have noticed that using non-PIC code in shared libraries are
not well supported. Not all ELF linkers even try to support such a
feature. Not many people are doing what you are trying to do. I
guess it is very low on the binutils's priority list. In your sparc
testcase, it seems that bfd is leaking memory. I don't have the
time to work on it. To make things worse, gdb on Sparc doesn't have
hardware watchpoints. It makes debugging very slow. As for the Linux
case, if you can trim your Linux testcase to a few small source files. I
will take a look when I find time.

-- 
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]