Fwd: PowerPC Disassembler Fails to Compile on CentOS 7
Joel Sherrill
joel at rtems.org
Thu May 6 15:25:24 UTC 2021
PowerPC failed to build on rtems7 and the next bump should fix it.
---------- Forwarded message ---------
From: Joel Sherrill <joel at rtems.org>
Date: Thu, May 6, 2021, 10:24 AM
Subject: Re: PowerPC Disassembler Fails to Compile on CentOS 7
To: H.J. Lu <hjl.tools at gmail.com>
Cc: binutils <binutils at sourceware.org>
Thanks. I guess the next bump in our bleeding edge tools will catch this
fix.
On Thu, May 6, 2021, 10:19 AM H.J. Lu <hjl.tools at gmail.com> wrote:
> On Thu, May 6, 2021 at 8:14 AM Joel Sherrill <joel at rtems.org> wrote:
> >
> > Hi
> >
> > binutils hash ed29efb which should be near the head appears to be
> assuming
> > that a newer GCC is being used which defaults to something else. The host
> > GCC reports:
> >
> > gcc (GCC) 4.8.5 20150623 (Red Hat 4.8.5-44)
> >
> > And the compilation fails with this:
> >
> > libtool: compile: gcc -O2 -g -pipe
> >
> -I/home/joel/rtems-cron-7/rtems-source-builder/rtems/build/tmp/sb-1001/7/rtems-powerpc/home/joel/rtems-cron-7/tools/7/include
> > -DHAVE_CONFIG_H -I.
> -I../../sourceware-mirror-binutils-gdb-ed29efb/opcodes
> > -I. -I../../sourceware-mirror-binutils-gdb-ed29efb/opcodes -I../bfd
> > -I../../sourceware-mirror-binutils-gdb-ed29efb/opcodes/../include
> > -I../../sourceware-mirror-binutils-gdb-ed29efb/opcodes/../bfd -W -Wall
> > -Wstrict-prototypes -Wmissing-prototypes -Wshadow -g -O2 -MT ppc-opc.lo
> -MD
> > -MP -MF .deps/ppc-opc.Tpo -c
> > ../../sourceware-mirror-binutils-gdb-ed29efb/opcodes/ppc-opc.c -o
> ppc-opc.o
> > mv -f .deps/disassemble.Tpo .deps/disassemble.Plo
> > ../../sourceware-mirror-binutils-gdb-ed29efb/opcodes/ppc-dis.c: In
> function
> > 'print_insn_powerpc':
> > mv -f .deps/dis-buf.Tpo .deps/dis-buf.Plo
> > ../../sourceware-mirror-binutils-gdb-ed29efb/opcodes/ppc-dis.c:1071:8:
> > error: 'for' loop initial declarations are only allowed in C99 mode
> > for (int i = 0; i < 2; i++)
> > ^
> > ../../sourceware-mirror-binutils-gdb-ed29efb/opcodes/ppc-dis.c:1071:8:
> > note: use option -std=c99 or -std=gnu99 to compile your code
> >
> > Should the code not declare i in the for loop of the compiler arguments
> add
> > C99?
> >
> > --joel
>
> Should be fixed by:
>
> commit a8d6316b67d52eaa1b7b311084ddff71a66f7cc0
> Author: Nick Clifton <nickc at redhat.com>
> Date: Tue May 4 13:40:34 2021 +0100
>
> Replace AC_PROG_CC with AC_PROG_CC_C99 in top level configure file.
>
> 2021-05-04 Nick Clifton <nickc at redhat.com>
>
> * configure.ac (AC_PROG_CC): Replace with AC_PROG_CC_C99.
> * configure: Regenerate.
>
> --
> H.J.
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rtems.org/pipermail/devel/attachments/20210506/344b2f72/attachment.html>
More information about the devel
mailing list