public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
* powerpc64-linux hack
@ 2003-08-11 11:29 Alan Modra
  2003-08-11 18:11 ` Ulrich Drepper
  2003-08-11 18:57 ` Richard Henderson
  0 siblings, 2 replies; 5+ messages in thread
From: Alan Modra @ 2003-08-11 11:29 UTC (permalink / raw)
  To: binutils; +Cc: mostrows

We won't ever be returning to anything in crt1.o, so a toc adjustment is
fine.

	* elf64-ppc.c (ppc64_elf_relocate_section): Add special case for crt1.o
	branch to __libc_start_main.

Index: bfd/elf64-ppc.c
===================================================================
RCS file: /cvs/src/src/bfd/elf64-ppc.c,v
retrieving revision 1.125
diff -u -p -r1.125 elf64-ppc.c
--- bfd/elf64-ppc.c	7 Aug 2003 08:38:08 -0000	1.125
+++ bfd/elf64-ppc.c	11 Aug 2003 11:25:15 -0000
@@ -7788,6 +7788,13 @@ ppc64_elf_relocate_section (bfd *output_
 		      if ((insn & 1) == 0)
 			can_plt_call = 1;
 		    }
+		  else if (h != NULL
+			   && strcmp (h->root.root.string,
+				      ".__libc_start_main") == 0)
+		    {
+		      /* Allow crt1 branch to go via a toc adjusting stub.  */
+		      can_plt_call = 1;
+		    }
 		  else
 		    {
 		      if (strcmp (input_section->output_section->name,

-- 
Alan Modra
IBM OzLabs - Linux Technology Centre

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2003-08-12  0:27 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-08-11 11:29 powerpc64-linux hack Alan Modra
2003-08-11 18:11 ` Ulrich Drepper
2003-08-12  0:25   ` Alan Modra
2003-08-11 18:57 ` Richard Henderson
2003-08-12  0:27   ` Alan Modra

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).