public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
* Don't complain about VxWorks GOT setup relocs on MIPS
@ 2010-09-19 10:06 Richard Sandiford
  0 siblings, 0 replies; only message in thread
From: Richard Sandiford @ 2010-09-19 10:06 UTC (permalink / raw)
  To: binutils

mips_check_relocs now has code to check for inappropriate HI, LO
and jump relocations in shared libraries.  This code was also
triggering for the standard VxWorks __GOTT_BASE__ and __GOTT_INDEX__
GP setup sequence, causing many failures in the existing testsuite.
This patch treats these symbols in the same way as _gp_disp.

Tested on mips-wrs-vxworks and applied.

Richard


bfd/
	* elfxx-mips.c (_bfd_mips_elf_check_relocs): On VxWorks,
	exclude __GOTT_BASE__ and __GOTT_INDEX__ from the warning
	about HI/LO relocations in shared objects.

Index: bfd/elfxx-mips.c
===================================================================
--- bfd/elfxx-mips.c	2010-09-04 10:16:11.000000000 +0100
+++ bfd/elfxx-mips.c	2010-09-04 10:16:46.000000000 +0100
@@ -7930,6 +7930,10 @@ _bfd_mips_elf_check_relocs (bfd *abfd, s
 		  && strcmp (h->root.root.string, "_gp_disp") == 0)
 		break;
 
+	      /* Likewise __GOTT_BASE__ and __GOTT_INDEX__ on VxWorks.  */
+	      if (is_gott_symbol (info, h))
+		break;
+
 	      /* FALLTHROUGH */
 
 	    case R_MIPS16_26:

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2010-09-19 10:06 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-09-19 10:06 Don't complain about VxWorks GOT setup relocs on MIPS Richard Sandiford

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).