* ldwrite.c (build_link_order <lang_padding_statement_enum>): Correct

condition under which we build a bfd_data_link_order.
This commit is contained in:
Alan Modra 2007-09-08 11:04:28 +00:00
parent 98ece1b313
commit c4e9ac527d
2 changed files with 9 additions and 1 deletions

View File

@ -1,3 +1,8 @@
2007-09-08 Alan Modra <amodra@bigpond.net.au>
* ldwrite.c (build_link_order <lang_padding_statement_enum>): Correct
condition under which we build a bfd_data_link_order.
2007-08-31 Tristan Gingold <gingold@adacore.com>
* ldlang.c (lang_map): Increment lang_statement_iteration so that

View File

@ -270,7 +270,10 @@ build_link_order (lang_statement_union_type *statement)
output_section = statement->padding_statement.output_section;
ASSERT (statement->padding_statement.output_section->owner
== output_bfd);
if ((output_section->flags & SEC_HAS_CONTENTS) != 0)
if (((output_section->flags & SEC_HAS_CONTENTS) != 0
|| ((output_section->flags & SEC_LOAD) != 0
&& (output_section->flags & SEC_THREAD_LOCAL)))
&& (output_section->flags & SEC_NEVER_LOAD) == 0)
{
link_order = bfd_new_link_order (output_bfd, output_section);
link_order->type = bfd_data_link_order;