[PATCH] C-SKY: Fix machine flag.
Mark Wielaard
mark@klomp.org
Tue Jan 17 12:53:05 GMT 2023
Hi,
On Tue, 2023-01-17 at 11:49 +0000, Nick Clifton via Binutils wrote:
> Hi Xianmiao Qu,
>
> > bfd/
> > * elf32-csky.c (elf32_csky_merge_attributes): Don't save
> > and restore the ARCH attribute, it will actually clear
> > the ARCH attribute.
> > (csky_elf_merge_private_bfd_data): Store the machine flag
> > correctly.
>
> Approved and applied.
Note that this broke the build on all arches:
https://builder.sourceware.org/buildbot/#/changes/17260
../../binutils-gdb/bfd/elf32-csky.c: In function
‘elf32_csky_merge_attributes’:
../../binutils-gdb/bfd/elf32-csky.c:2867:17: error: unused variable
‘tattr’ [-Werror=unused-variable]
2867 | obj_attribute tattr;
| ^~~~~
../../binutils-gdb/bfd/elf32-csky.c: In function
‘csky_elf_merge_private_bfd_data’:
../../binutils-gdb/bfd/elf32-csky.c:3067:56: error: suggest parentheses
around comparison in operand of ‘&’ [-Werror=parentheses]
3067 | || (new_flags & (CSKY_ARCH_MASK | CSKY_ABI_MASK) !=
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~
3068 | old_flags & (CSKY_ARCH_MASK | CSKY_ABI_MASK)))
| ~~~~~~~~~
cc1: all warnings being treated as errors
make[3]: *** [Makefile:1765: elf32-csky.lo] Error 1
make[3]: *** Waiting for unfinished jobs....
More information about the Binutils
mailing list