This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
Re: [patch bfd]: Don't emit auxilary information for discared sections for pe-coff
- From: Alan Modra <amodra at gmail dot com>
- To: Kai Tietz <ktietz70 at googlemail dot com>
- Cc: Binutils <binutils at sourceware dot org>
- Date: Thu, 29 Sep 2011 14:23:57 +0930
- Subject: Re: [patch bfd]: Don't emit auxilary information for discared sections for pe-coff
- References: <CAEwic4Zr8owNhXzrhgXWSursR=ynxUVPrQhBpBzQugLgnkW==w@mail.gmail.com>
On Tue, Sep 27, 2011 at 02:38:19PM +0200, Kai Tietz wrote:
> diff -u -r1.80 coffgen.c
> --- bfd/coffgen.c 17 Aug 2011 00:39:39 -0000 1.80
> +++ bfd/coffgen.c 27 Sep 2011 11:21:47 -0000
> @@ -921,6 +921,9 @@
> void * buf;
> bfd_size_type symesz;
>
> + if ((bfd_get_section_flags (abfd, symbol->section) & SEC_LINK_ONCE) != 0
> + && symbol->section->output_section == bfd_abs_section_ptr)
> + return TRUE;
Conditional on link_info.strip_discarded?
> if (native->u.syment.n_sclass == C_FILE)
> symbol->flags |= BSF_DEBUGGING;
>
> @@ -996,7 +999,10 @@
> asection *output_section = symbol->section->output_section
> ? symbol->section->output_section
> : symbol->section;
> -
> + if ((bfd_get_section_flags (abfd, symbol->section) & SEC_LINK_ONCE) != 0
> + && symbol->section->output_section
> + == bfd_abs_section_ptr)
> + return TRUE;
This hunk seems unnecessary, given that coff_write_alien_symbol calls
coff_write_symbol.
--
Alan Modra
Australia Development Lab, IBM