This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
Re: [PATCH] BFD/ELF: Correct a `remove' global shadowing error for pre-4.8 GCC
On Mon, Jul 09, 2018 at 09:17:37PM +0100, Maciej W. Rozycki wrote:
> Remove `-Wshadow' compilation errors:
>
> cc1: warnings being treated as errors
> .../bfd/elflink.c: In function 'bfd_elf_final_link':
> .../bfd/elflink.c:11722: error: declaration of 'remove' shadows a global declaration
> /usr/include/stdio.h:154: error: shadowed declaration is here
>
> which for versions of GCC before 4.8 prevent support for ELF targets
> from being built. See also GCC PR c/53066.
>
> bfd/
> * elflink.c (bfd_elf_final_link): Rename `remove' local variable
> to `remove_section'.
Please apply. This should go on the branch too.
--
Alan Modra
Australia Development Lab, IBM