aboutsummaryrefslogtreecommitdiff
path: root/ld
diff options
context:
space:
mode:
authorJeff Law <law@redhat.com>1994-02-25 18:51:35 +0000
committerJeff Law <law@redhat.com>1994-02-25 18:51:35 +0000
commita62494c41be4df5acbb36f1fac4ac6018771e60c (patch)
tree80c8a159525448ab96b4eb3ecf838834e12e1b36 /ld
parent25354cef30be4a7ea7731b897a35c62b2c47cbbd (diff)
downloadgdb-a62494c41be4df5acbb36f1fac4ac6018771e60c.zip
gdb-a62494c41be4df5acbb36f1fac4ac6018771e60c.tar.gz
gdb-a62494c41be4df5acbb36f1fac4ac6018771e60c.tar.bz2
* ldlang.c (lang_size_sections): No longer static (PA ELF calls
it via hppaelf_finish). Prototype moved into ldlang.h. (lang_process): Move problematic extra call to lang_size_sections into the PA ELF specific code. * emultempl/hppaelf.em (hppaelf_finish): Extra call to lang_size_sections moved here.
Diffstat (limited to 'ld')
-rw-r--r--ld/ChangeLog9
-rw-r--r--ld/emultempl/hppaelf.em5
-rw-r--r--ld/ldlang.c21
3 files changed, 17 insertions, 18 deletions
diff --git a/ld/ChangeLog b/ld/ChangeLog
index 4e08c95..21fc924 100644
--- a/ld/ChangeLog
+++ b/ld/ChangeLog
@@ -1,3 +1,12 @@
+Fri Feb 25 10:47:25 1994 Jeffrey A. Law (law@snake.cs.utah.edu)
+
+ * ldlang.c (lang_size_sections): No longer static (PA ELF calls
+ it via hppaelf_finish). Prototype moved into ldlang.h.
+ (lang_process): Move problematic extra call to lang_size_sections
+ into the PA ELF specific code.
+ * emultempl/hppaelf.em (hppaelf_finish): Extra call to
+ lang_size_sections moved here.
+
Thu Feb 24 16:47:33 1994 Ian Lance Taylor (ian@cygnus.com)
* configure.in (powerpc-*-elf*): New target; use ppc-elf32.
diff --git a/ld/emultempl/hppaelf.em b/ld/emultempl/hppaelf.em
index 14a2fe8..128cdda 100644
--- a/ld/emultempl/hppaelf.em
+++ b/ld/emultempl/hppaelf.em
@@ -153,6 +153,11 @@ hppaelf_finish()
/* they are no longer valid */
hppaelf_search_for_padding_statements(stat_ptr->head,&(stat_ptr->head));
}
+ /* Size up the sections again. */
+ lang_size_sections (stat_ptr->head,
+ abs_output_section,
+ &(stat_ptr->head), 0, (bfd_vma) 0, false);
+
}
static void
diff --git a/ld/ldlang.c b/ld/ldlang.c
index e78d31b..d0d3663 100644
--- a/ld/ldlang.c
+++ b/ld/ldlang.c
@@ -127,11 +127,6 @@ static bfd_vma size_input_section
PARAMS ((lang_statement_union_type **this_ptr,
lang_output_section_statement_type *output_section_statement,
fill_type fill, bfd_vma dot, boolean relax));
-static bfd_vma lang_size_sections
- PARAMS ((lang_statement_union_type *s,
- lang_output_section_statement_type *output_section_statement,
- lang_statement_union_type **prev, fill_type fill,
- bfd_vma dot, boolean relax));
static bfd_vma lang_do_assignments
PARAMS ((lang_statement_union_type * s,
lang_output_section_statement_type *output_section_statement,
@@ -1588,7 +1583,7 @@ size_input_section (this_ptr, output_section_statement, fill, dot, relax)
*/
static boolean had_relax;
-static bfd_vma
+bfd_vma
lang_size_sections (s, output_section_statement, prev, fill, dot, relax)
lang_statement_union_type * s;
lang_output_section_statement_type * output_section_statement;
@@ -1649,8 +1644,9 @@ lang_size_sections (s, output_section_statement, prev, fill, dot, relax)
/* The section starts here */
/* First, align to what the section needs */
+ if (os->section_alignment != -1)
+ dot = align_power (dot, os->section_alignment);
- dot = align_power (dot, os->bfd_section->alignment_power);
bfd_set_section_vma (0, os->bfd_section, dot);
if (os->load_base) {
@@ -2537,17 +2533,6 @@ lang_process ()
/* Final stuffs */
ldemul_finish ();
-
-#if 0
- /* DO NOT REENABLE THIS CALL. IF THIS CALL IS MADE, THE SUN4 LINKER
- CAN NOT BOOTSTRAP!! No, I don't know why, but don't change it
- unless you fix it. */
- /* Size up the sections. */
- lang_size_sections (statement_list.head,
- abs_output_section,
- &(statement_list.head), 0, (bfd_vma) 0, false);
-#endif
-
lang_finish ();
}