forked from Imagelibrary/binutils-gdb
* ldlang.c (insert_pad): Correct output section size calculation.
(lang_size_sections_1): Likewise for lang_data_statement and lang_reloc_statement.
This commit is contained in:
@@ -1,3 +1,9 @@
|
|||||||
|
2012-11-01 Alan Modra <amodra@gmail.com>
|
||||||
|
|
||||||
|
* ldlang.c (insert_pad): Correct output section size calculation.
|
||||||
|
(lang_size_sections_1): Likewise for lang_data_statement and
|
||||||
|
lang_reloc_statement.
|
||||||
|
|
||||||
2012-10-29 Alan Modra <amodra@gmail.com>
|
2012-10-29 Alan Modra <amodra@gmail.com>
|
||||||
|
|
||||||
* configure.tgt (powerpcle-pe,winnt,cygwin): Add deffilep.o
|
* configure.tgt (powerpcle-pe,winnt,cygwin): Add deffilep.o
|
||||||
|
|||||||
10
ld/ldlang.c
10
ld/ldlang.c
@@ -4594,7 +4594,8 @@ insert_pad (lang_statement_union_type **ptr,
|
|||||||
}
|
}
|
||||||
pad->padding_statement.output_offset = dot - output_section->vma;
|
pad->padding_statement.output_offset = dot - output_section->vma;
|
||||||
pad->padding_statement.size = alignment_needed;
|
pad->padding_statement.size = alignment_needed;
|
||||||
output_section->size += alignment_needed;
|
output_section->size = TO_SIZE (dot + TO_ADDR (alignment_needed)
|
||||||
|
- output_section->vma);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Work out how much this section will move the dot point. */
|
/* Work out how much this section will move the dot point. */
|
||||||
@@ -5159,7 +5160,9 @@ lang_size_sections_1
|
|||||||
if (size < TO_SIZE ((unsigned) 1))
|
if (size < TO_SIZE ((unsigned) 1))
|
||||||
size = TO_SIZE ((unsigned) 1);
|
size = TO_SIZE ((unsigned) 1);
|
||||||
dot += TO_ADDR (size);
|
dot += TO_ADDR (size);
|
||||||
output_section_statement->bfd_section->size += size;
|
output_section_statement->bfd_section->size
|
||||||
|
= TO_SIZE (dot - output_section_statement->bfd_section->vma);
|
||||||
|
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
@@ -5173,7 +5176,8 @@ lang_size_sections_1
|
|||||||
output_section_statement->bfd_section;
|
output_section_statement->bfd_section;
|
||||||
size = bfd_get_reloc_size (s->reloc_statement.howto);
|
size = bfd_get_reloc_size (s->reloc_statement.howto);
|
||||||
dot += TO_ADDR (size);
|
dot += TO_ADDR (size);
|
||||||
output_section_statement->bfd_section->size += size;
|
output_section_statement->bfd_section->size
|
||||||
|
= TO_SIZE (dot - output_section_statement->bfd_section->vma);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user