elf bfd.h tidy
[deliverable/binutils-gdb.git] / ld / emultempl / ppc32elf.em
index 5387ef1a6c8c3c737212e591b26ca7340b600528..056068edb1989bd85fda0663912edf7d9751984c 100644 (file)
@@ -19,7 +19,7 @@
 # MA 02110-1301, USA.
 #
 
-# This file is sourced from elf32.em, and defines extra powerpc32-elf
+# This file is sourced from elf.em, and defines extra powerpc32-elf
 # specific routines.
 #
 fragment <<EOF
@@ -171,7 +171,12 @@ ppc_before_allocation (void)
       bfd_vma high = 0;
       asection *o;
 
-      /* Run lang_size_sections (if not already done).  */
+      /* Run lang_size_sections even if already done, so as to pick
+        up gld${EMULATION_NAME}_before_allocation sizing.  This
+        matters when we have an executable bss plt which will
+        typically be laid out near the end of the image, ie. worst
+        case for branches at the start of .text.  */
+      expld.phase = lang_first_phase_enum;
       prelim_size_sections ();
 
       for (o = link_info.output_bfd->sections; o != NULL; o = o->next)
@@ -242,7 +247,6 @@ if grep -q 'ld_elf32_spu_emulation' ldemul-list.h; then
   fragment <<EOF
 /* Special handling for embedded SPU executables.  */
 extern bfd_boolean embedded_spu_file (lang_input_statement_type *, const char *);
-static bfd_boolean gld${EMULATION_NAME}_load_symbols (lang_input_statement_type *);
 
 static bfd_boolean
 ppc_recognized_file (lang_input_statement_type *entry)
@@ -250,7 +254,7 @@ ppc_recognized_file (lang_input_statement_type *entry)
   if (embedded_spu_file (entry, "-m32"))
     return TRUE;
 
-  return gld${EMULATION_NAME}_load_symbols (entry);
+  return ldelf_load_symbols (entry);
 }
 
 EOF
This page took 0.024823 seconds and 4 git commands to generate.