This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
[gold commit] PR 18847: Fix problem where script specified both address and region for a section
- From: Cary Coutant <ccoutant at gmail dot com>
- To: Binutils <binutils at sourceware dot org>
- Date: Wed, 26 Aug 2015 00:04:56 -0700
- Subject: [gold commit] PR 18847: Fix problem where script specified both address and region for a section
- Authentication-results: sourceware.org; auth=none
If a script specifies both address and region for an output section
declaration, gold ignores the region specification. This can lead to
bogus "moves backward" errors. This patch fixes gold so that if a
section specifies both address and region, it will place the section
at the specified address in the region, and update the location counter
within the region.
-cary
2015-08-25 Cary Coutant <ccoutant@gmail.com>
gold/
PR gold/18847
* script-sections.cc (Memory_region::set_address): New method.
(Script_sections::find_memory_region): Add explicit_only parameter.
(Output_section_definition::set_section_addresses): Handle case where
script specifies both address and vma region.
* script-sections.h (Script_sections::find_memory_region): Add
explicit_only parameter.