This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
Re: [BUILDROBOT] error: comparison between ʽbfd_reloc_code_real_typeʼ and ʽenum elf_mips_reloc_typeʼ (was: MIPS: Verify the ISA mode and alignment of branch and jump targets)1;5C
- From: "Maciej W. Rozycki" <macro at imgtec dot com>
- To: Jan-Benedict Glaw <jbglaw at lug-owl dot de>
- Cc: <binutils at sourceware dot org>
- Date: Wed, 20 Jul 2016 12:59:12 +0100
- Subject: Re: [BUILDROBOT] error: comparison between ʽbfd_reloc_code_real_typeʼ and ʽenum elf_mips_reloc_typeʼ (was: MIPS: Verify the ISA mode and alignment of branch and jump targets)1;5C
- Authentication-results: sourceware.org; auth=none
- References: <alpine.DEB.2.00.1607181846110.4076@tp.orcam.me.uk> <20160719161529.GC4454@lug-owl.de>
On Tue, 19 Jul 2016, Jan-Benedict Glaw wrote:
> On gcc21 (compile farm), I'm seeing this with Ubuntu 4.8.4-2ubuntu1~14.04.3:
>
>
> gcc -DHAVE_CONFIG_H -I. -I/scratch/4/jbglaw/regular/repos/binutils_gdb/gas -I. -I/scratch/4/jbglaw/regular/repos/binutils_gdb/gas -I../bfd -I/scratch/4/jbglaw/regular/repos/binutils_gdb/gas/config -I/scratch/4/jbglaw/regular/repos/binutils_gdb/gas/../include -I/scratch/4/jbglaw/regular/repos/binutils_gdb/gas/.. -I/scratch/4/jbglaw/regular/repos/binutils_gdb/gas/../bfd -DLOCALEDIR="\"/scratch/4/jbglaw/regular/build/mips-linux/_install_/share/locale\"" -W -Wall -Wstrict-prototypes -Wmissing-prototypes -Wshadow -Werror -Wwrite-strings -I/scratch/4/jbglaw/regular/repos/binutils_gdb/gas/../zlib -g -O2 -MT tc-mips.o -MD -MP -MF .deps/tc-mips.Tpo -c -o tc-mips.o `test -f 'config/tc-mips.c' || echo '/scratch/4/jbglaw/regular/repos/binutils_gdb/gas/'`config/tc-mips.c
> /scratch/4/jbglaw/regular/repos/binutils_gdb/gas/config/tc-mips.c: In function ʽmips_force_relocationʼ:
> /scratch/4/jbglaw/regular/repos/binutils_gdb/gas/config/tc-mips.c:14807:24: error: comparison between ʽbfd_reloc_code_real_typeʼ and ʽenum elf_mips_reloc_typeʼ [-Werror=enum-compare]
> if ((fixp->fx_r_type == R_MIPS_PC26_S2
> ^
> /scratch/4/jbglaw/regular/repos/binutils_gdb/gas/config/tc-mips.c:14808:27: error: comparison between ʽbfd_reloc_code_real_typeʼ and ʽenum elf_mips_reloc_typeʼ [-Werror=enum-compare]
> || fixp->fx_r_type == R_MIPS_PC21_S2
Fixed with commit 5caa2b07ebd1 ("MIPS/GAS: Remove erroneous ELF
relocation references").
> /scratch/4/jbglaw/regular/repos/binutils_gdb/gas/config/tc-mips.c: In function ʽfix_bad_cross_mode_branch_pʼ:
> /scratch/4/jbglaw/regular/repos/binutils_gdb/gas/config/tc-mips.c:14959:17: error: variable ʽopcodeʼ set but not used [-Werror=unused-but-set-variable]
> unsigned long opcode;
> ^
> cc1: all warnings being treated as errors
> make[3]: *** [tc-mips.o] Error 1
>
>
> The first two (R_MIPS_PC21_S2 comparisons) still hold true, the opcode
> warning might be gone since the latest change.
Indeed, the latter was an artefact of bad code shuffling between patches.
Apologies about the breakage and thanks for the alert!
Maciej