PR ld/12380
commit19f43cc1c8b21de0f5cefd57971d0703bee5d809
authorAlan Modra <amodra@bigpond.net.au>
Wed, 12 Jan 2011 12:07:19 +0000 (12 12:07 +0000)
committerAlan Modra <amodra@bigpond.net.au>
Wed, 12 Jan 2011 12:07:19 +0000 (12 12:07 +0000)
tree5386d31af1af71f9be8ec9dcbf6ca26c5d4fb598
parentde1174204492861212f8676d1386cbbec3e76008
PR ld/12380
* ldexp.h (enum phase_enum): Comment.  Add exp_dataseg_done.
* ldexp.c (fold_unary <DATA_SEGMENT_END>): Rearrange code.  Test
for exp_dataseg_done rather than expld.phase == lang_final_phase_enum
to detect when we've finished sizing sections.
(fold_binary <DATA_SEGMENT_ALIGN>): Likewise.
(fold_binary <DATA_SEGMENT_RELRO_END>): Likewise.  Also test
that we are not inside an output section statement.
* ldlang.c (lang_size_sections): Set exp_dataseg_done on exit if
not exp_dataseg_relro_adjust or exp_dataseg_adjust.  Don't set
lang_final_phase_enum here.
(lang_process): Set lang_final_phase_enum here.
ld/ChangeLog
ld/ldexp.c
ld/ldexp.h
ld/ldlang.c