This is the mail archive of the binutils@sourceware.org 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]
Other format: [Raw text]

Re: PATCH: Support VER_FLG_INFO in readelf


David Miller <davem@davemloft.net> writes:

> Ok, was libstdc++.a built using -fPIC?

Without, though I wonder why gold uses libstdc++.a instead of
libstdc++.so here.

> The assembler should never emit R_SPARC_WPLT30 for a call instruction
> unless PIC was specified on the command line.
>
> R_SPARC_WPLT30 specifically instructs the linker to create a PLT entry
> for the symbol reference.
>
> If Sun's assembler is emitting this for a non-PIC build, that's
> extremely unfortunate.
>
> Ugh! From bfd/elfxx-sparc.c:
>
> 	case R_SPARC_WPLT30:
>  ...
> 	  if (h == NULL)
> 	    {
> 	      if (! ABI_64_P (abfd))
> 		{
> 		  /* The Solaris native assembler will generate a WPLT30
> 		     reloc for a local symbol if you assemble a call from
> 		     one section to another when using -K pic.  We treat
> 		     it as WDISP30.  */

This might be related to its inability to compute the difference between
symbols in different sections.

> So I guess I'll have to add something to GOLD to handle this too.

That would really help :-)

Thanks.
	Rainer

-- 
-----------------------------------------------------------------------------
Rainer Orth, Center for Biotechnology, Bielefeld University


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