aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2012-05-30 04:19:11 +0000
committerAlan Modra <amodra@gmail.com>2012-05-30 04:19:11 +0000
commit6d8bf25d7e9b6fa7cff57137e7c55bcb11b227d8 (patch)
treef1e29ca76d1291788cd71991ae5d8c4e88f85bb6
parentebd86fb5688dac848266e6a902ea192fe9aa1576 (diff)
downloadgdb-6d8bf25d7e9b6fa7cff57137e7c55bcb11b227d8.zip
gdb-6d8bf25d7e9b6fa7cff57137e7c55bcb11b227d8.tar.gz
gdb-6d8bf25d7e9b6fa7cff57137e7c55bcb11b227d8.tar.bz2
* ldlang.h (lang_output_section_statement_type): Rename
"section_relative_symbol" field to "update_dot". * ldlang.c: Update all uses. (strip_excluded_output_sections): Don't test update_dot_tree here.. (lang_leave_overlay): ..set update_dot here.
-rw-r--r--ld/ChangeLog8
-rw-r--r--ld/ldlang.c12
-rw-r--r--ld/ldlang.h4
3 files changed, 17 insertions, 7 deletions
diff --git a/ld/ChangeLog b/ld/ChangeLog
index f513cc6..caad59d 100644
--- a/ld/ChangeLog
+++ b/ld/ChangeLog
@@ -1,3 +1,11 @@
+2012-05-30 Alan Modra <amodra@gmail.com>
+
+ * ldlang.h (lang_output_section_statement_type): Rename
+ "section_relative_symbol" field to "update_dot".
+ * ldlang.c: Update all uses.
+ (strip_excluded_output_sections): Don't test update_dot_tree here..
+ (lang_leave_overlay): ..set update_dot here.
+
2012-05-26 Alan Modra <amodra@gmail.com>
* ldlex.h (enum option_values): Move from..
diff --git a/ld/ldlang.c b/ld/ldlang.c
index f4eb703..4e75624 100644
--- a/ld/ldlang.c
+++ b/ld/ldlang.c
@@ -3889,8 +3889,7 @@ strip_excluded_output_sections (void)
{
/* We don't set bfd_section to NULL since bfd_section of the
removed output section statement may still be used. */
- if (!os->section_relative_symbol
- && !os->update_dot_tree)
+ if (!os->update_dot)
os->ignored = TRUE;
output_section->flags |= SEC_EXCLUDE;
bfd_section_list_remove (link_info.output_bfd, output_section);
@@ -5253,7 +5252,7 @@ lang_size_sections_1
|| tree->type.node_class == etree_assign)
&& (tree->assign.dst [0] != '.'
|| tree->assign.dst [1] != '\0'))
- output_section_statement->section_relative_symbol = 1;
+ output_section_statement->update_dot = 1;
if (!output_section_statement->ignored)
{
@@ -7390,8 +7389,11 @@ lang_leave_overlay (etree_type *lma_expr,
/* After setting the size of the last section, set '.' to end of the
overlay region. */
if (overlay_list != NULL)
- overlay_list->os->update_dot_tree
- = exp_assign (".", exp_binop ('+', overlay_vma, overlay_max));
+ {
+ overlay_list->os->update_dot = 1;
+ overlay_list->os->update_dot_tree
+ = exp_assign (".", exp_binop ('+', overlay_vma, overlay_max));
+ }
l = overlay_list;
while (l != NULL)
diff --git a/ld/ldlang.h b/ld/ldlang.h
index b5d50c5..7f1e743 100644
--- a/ld/ldlang.h
+++ b/ld/ldlang.h
@@ -163,8 +163,8 @@ typedef struct lang_output_section_statement_struct
unsigned int all_input_readonly : 1;
/* If this section should be ignored. */
unsigned int ignored : 1;
- /* If there is a symbol relative to this section. */
- unsigned int section_relative_symbol : 1;
+ /* If this section should update "dot". Prevents section being ignored. */
+ unsigned int update_dot : 1;
} lang_output_section_statement_type;
typedef struct