summaryrefslogtreecommitdiff
path: root/gas/dwarf2dbg.c
diff options
context:
space:
mode:
Diffstat (limited to 'gas/dwarf2dbg.c')
-rw-r--r--gas/dwarf2dbg.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/gas/dwarf2dbg.c b/gas/dwarf2dbg.c
index 3336453a4ee..59da56ab55a 100644
--- a/gas/dwarf2dbg.c
+++ b/gas/dwarf2dbg.c
@@ -1371,7 +1371,7 @@ dwarf2_finish (void)
/* Create and switch to the line number section. */
line_seg = subseg_new (".debug_line", 0);
- bfd_set_section_flags (stdoutput, line_seg, SEC_READONLY);
+ bfd_set_section_flags (stdoutput, line_seg, SEC_READONLY | SEC_DEBUGGING);
/* For each subsection, chain the debug entries together. */
for (s = all_segs; s; s = s->next)
@@ -1400,9 +1400,12 @@ dwarf2_finish (void)
abbrev_seg = subseg_new (".debug_abbrev", 0);
aranges_seg = subseg_new (".debug_aranges", 0);
- bfd_set_section_flags (stdoutput, info_seg, SEC_READONLY);
- bfd_set_section_flags (stdoutput, abbrev_seg, SEC_READONLY);
- bfd_set_section_flags (stdoutput, aranges_seg, SEC_READONLY);
+ bfd_set_section_flags (stdoutput, info_seg,
+ SEC_READONLY | SEC_DEBUGGING);
+ bfd_set_section_flags (stdoutput, abbrev_seg,
+ SEC_READONLY | SEC_DEBUGGING);
+ bfd_set_section_flags (stdoutput, aranges_seg,
+ SEC_READONLY | SEC_DEBUGGING);
record_alignment (aranges_seg, ffs (2 * sizeof_address) - 1);