|
View:
New views
4 Messages
—
Rating Filter:
Alert me
|
|
|
Errors occurred when building GDB using instuctions from EAN2 at www.embecosm.comHi everyone,
When I build GDB following instructions from EAN2, the following errors occurred, it may be caused by "warnings being treated as errors" because of flag "-Werror", can anyone help to fix this? Thanks very much! I build it in Ubuntu, using gcc 4.1.3 Regards. Sigma HH //--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- ...................... config.status: creating gdb.threads/Makefile config.status: creating gdb.trace/Makefile config.status: creating gdb.xml/Makefile make[2]: Entering directory `/home/xuebo/downloads/or1k_downloads/build_gdb/sim' make[2]: Leaving directory `/home/xuebo/downloads/or1k_downloads/build_gdb/sim' make[2]: Entering directory `/home/xuebo/downloads/or1k_downloads/build_gdb/gdb' CONFIG_HEADERS=config.h:config.in \ CONFIG_COMMANDS=default \ CONFIG_FILES= \ CONFIG_LINKS= \ /bin/bash config.status config.status: creating config.h config.status: config.h is unchanged config.status: executing default commands gcc -c -g -O2 -I. -I../../gdb-6.8/gdb -I../../gdb-6.8/gdb/config -DLOCALEDIR="\"/opt/or32/share/locale\"" -DHAVE_CONFIG_H -I../../gdb-6.8/gdb/../include/opcode -I../../gdb-6.8/gdb/../readline/.. -I../bfd -I../../gdb-6.8/gdb/../bfd -I../../gdb-6.8/gdb/../include -I../libdecnumber -I../../gdb-6.8/gdb/../libdecnumber -DMI_OUT=1 -DTUI=1 -Wall -Wdeclaration-after-statement -Wpointer-arith -Wformat-nonliteral -Wno-pointer-sign -Wno-unused -Wno-switch -Wno-char-subscripts -Werror ../../gdb-6.8/gdb/gdb.c gcc -c -g -O2 -I. -I../../gdb-6.8/gdb -I../../gdb-6.8/gdb/config -DLOCALEDIR="\"/opt/or32/share/locale\"" -DHAVE_CONFIG_H -I../../gdb-6.8/gdb/../include/opcode -I../../gdb-6.8/gdb/../readline/.. -I../bfd -I../../gdb-6.8/gdb/../bfd -I../../gdb-6.8/gdb/../include -I../libdecnumber -I../../gdb-6.8/gdb/../libdecnumber -DMI_OUT=1 -DTUI=1 -Wall -Wdeclaration-after-statement -Wpointer-arith -Wformat-nonliteral -Wno-pointer-sign -Wno-unused -Wno-switch -Wno-char-subscripts -Werror ../../gdb-6.8/gdb/or1k-tdep.c cc1: warnings being treated as errors ../../gdb-6.8/gdb/or1k-tdep.c: In function ‘or1k_frame_unwind_cache’: ../../gdb-6.8/gdb/or1k-tdep.c:705: warning: format ‘%08llx’ expects type ‘long long unsigned int’, but argument 2 has type ‘CORE_ADDR’ ../../gdb-6.8/gdb/or1k-tdep.c:724: warning: format ‘%08llx’ expects type ‘long long unsigned int’, but argument 2 has type ‘CORE_ADDR’ ../../gdb-6.8/gdb/or1k-tdep.c:732: warning: format ‘%08llx’ expects type ‘long long unsigned int’, but argument 2 has type ‘CORE_ADDR’ ../../gdb-6.8/gdb/or1k-tdep.c: In function ‘or1k_skip_prologue’: ../../gdb-6.8/gdb/or1k-tdep.c:1374: warning: format ‘%08llx’ expects type ‘long long unsigned int’, but argument 2 has type ‘CORE_ADDR’ ../../gdb-6.8/gdb/or1k-tdep.c:1399: warning: format ‘%08llx’ expects type ‘long long unsigned int’, but argument 2 has type ‘CORE_ADDR’ ../../gdb-6.8/gdb/or1k-tdep.c:1413: warning: format ‘%08llx’ expects type ‘long long unsigned int’, but argument 2 has type ‘CORE_ADDR’ ../../gdb-6.8/gdb/or1k-tdep.c:1442: warning: format ‘%08llx’ expects type ‘long long unsigned int’, but argument 2 has type ‘CORE_ADDR’ ../../gdb-6.8/gdb/or1k-tdep.c:1475: warning: format ‘%08llx’ expects type ‘long long unsigned int’, but argument 2 has type ‘CORE_ADDR’ ../../gdb-6.8/gdb/or1k-tdep.c: In function ‘or1k_write_spr’: ../../gdb-6.8/gdb/or1k-tdep.c:2854: warning: format ‘%8llx’ expects type ‘long long unsigned int’, but argument 4 has type ‘long unsigned int’ ../../gdb-6.8/gdb/or1k-tdep.c: In function ‘or1k_info_spr_command’: ../../gdb-6.8/gdb/or1k-tdep.c:2900: warning: format ‘%llu’ expects type ‘long long unsigned int’, but argument 8 has type ‘long unsigned int’ ../../gdb-6.8/gdb/or1k-tdep.c:2900: warning: format ‘%llx’ expects type ‘long long unsigned int’, but argument 9 has type ‘long unsigned int’ ../../gdb-6.8/gdb/or1k-tdep.c:2915: warning: format ‘%llu’ expects type ‘long long unsigned int’, but argument 8 has type ‘long unsigned int’ ../../gdb-6.8/gdb/or1k-tdep.c:2915: warning: format ‘%llx’ expects type ‘long long unsigned int’, but argument 9 has type ‘long unsigned int’ ../../gdb-6.8/gdb/or1k-tdep.c: In function ‘or1k_spr_command’: ../../gdb-6.8/gdb/or1k-tdep.c:2972: warning: format ‘%llu’ expects type ‘long long unsigned int’, but argument 8 has type ‘long unsigned int’ ../../gdb-6.8/gdb/or1k-tdep.c:2972: warning: format ‘%llx’ expects type ‘long long unsigned int’, but argument 9 has type ‘long unsigned int’ ../../gdb-6.8/gdb/or1k-tdep.c:2972: warning: format ‘%llu’ expects type ‘long long unsigned int’, but argument 10 has type ‘long unsigned int’ ../../gdb-6.8/gdb/or1k-tdep.c:2972: warning: format ‘%llx’ expects type ‘long long unsigned int’, but argument 11 has type ‘long unsigned int’ make[2]: *** [or1k-tdep.o] Error 1 make[2]: Leaving directory `/home/xuebo/downloads/or1k_downloads/build_gdb/gdb' make[1]: *** [all-gdb] Error 2 make[1]: Leaving directory `/home/xuebo/downloads/or1k_downloads/build_gdb' make: *** [all] Error 2 xuebo@ubuntu:~/downloads/or1k_downloads/build_gdb$ ls //------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ _______________________________________________ http://www.opencores.org/mailman/listinfo/openrisc |
|
|
Re: Errors occurred when building GDB using instuctions from EAN2 at www.embecosm.comOn Thu, 2009-02-26 at 22:31 +0800, Sigma HH wrote:
> Hi everyone, > > When I build GDB following instructions from EAN2, the following > errors occurred, it may be caused by "warnings being treated as > errors" because of flag "-Werror", can anyone help to fix this? Thanks > very much! > Hi Sigma HH, Thanks for the heads up on this. I haven't seen this with GCC 4.3.0 on Fedora. I am rather surprised that GCC complains about CORE_ADDR being unsuitable for %08llx, since CORE_ADDR is a typedef for unsigned long long. The complaints about using %llu for unsigned long are more reasonable. I'm surprised I haven't seen this as a fault with GCC 4.3.0. Please would you file it as a bug in the OR1200 tracker (http://www.opencores.org/ptracker.cgi/list/or1k), so we can get it fixed. These problems occur in the code for the legacy OpenRISC JTAG interface, which has now been replaced by the standard RSP interface. Pending a new release of GDB, I suggest you go through or1k-tdep.c and explicitly cast each of the arguments causing complaint to unsigned long long). HTH, Jeremy > I build it in Ubuntu, using gcc 4.1.3 > > Regards. > > Sigma HH > > //--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- > > ...................... > > config.status: creating gdb.threads/Makefile > config.status: creating gdb.trace/Makefile > config.status: creating gdb.xml/Makefile > make[2]: Entering directory > `/home/xuebo/downloads/or1k_downloads/build_gdb/sim' > make[2]: Leaving directory > `/home/xuebo/downloads/or1k_downloads/build_gdb/sim' > make[2]: Entering directory > `/home/xuebo/downloads/or1k_downloads/build_gdb/gdb' > CONFIG_HEADERS=config.h:config.in \ > CONFIG_COMMANDS=default \ > CONFIG_FILES= \ > CONFIG_LINKS= \ > /bin/bash config.status > config.status: creating config.h > config.status: config.h is unchanged > config.status: executing default commands > gcc -c -g -O2 -I. -I../../gdb-6.8/gdb -I../../gdb-6.8/gdb/config > -DLOCALEDIR="\"/opt/or32/share/locale\"" -DHAVE_CONFIG_H > -I./../gdb-6.8/gdb/../include/opcode > -I../../gdb-6.8/gdb/../readline/.. -I../bfd -I../../gdb-6.8/gdb/../bfd > -I../../gdb-6.8/gdb/../include -I../libdecnumber > -I../../gdb-6.8/gdb/../libdecnumber -DMI_OUT=1 -DTUI=1 -Wall > -Wdeclaration-after-statement -Wpointer-arith -Wformat-nonliteral > -Wno-pointer-sign -Wno-unused -Wno-switch -Wno-char-subscripts > -Werror ../../gdb-6.8/gdb/gdb.c > gcc -c -g -O2 -I. -I../../gdb-6.8/gdb -I../../gdb-6.8/gdb/config > -DLOCALEDIR="\"/opt/or32/share/locale\"" -DHAVE_CONFIG_H > -I../../gdb-6.8/gdb/../include/opcode > -I../../gdb-6.8/gdb/../readline/.. -I../bfd -I../../gdb-6.8/gdb/../bfd > -I../../gdb-6.8/gdb/../include -I../libdecnumber > -I../../gdb-6.8/gdb/../libdecnumber -DMI_OUT=1 -DTUI=1 -Wall > -Wdeclaration-after-statement -Wpointer-arith -Wformat-nonliteral > -Wno-pointer-sign -Wno-unused -Wno-switch -Wno-char-subscripts > -Werror ../../gdb-6.8/gdb/or1k-tdep.c > cc1: warnings being treated as errors > ../../gdb-6.8/gdb/or1k-tdep.c: In function ‘or1k_frame_unwind_cache’: > ../../gdb-6.8/gdb/or1k-tdep.c:705: warning: format ‘%08llx’ expects > type ‘long long unsigned int’, but argument 2 has type ‘CORE_ADDR’ > ../../gdb-6.8/gdb/or1k-tdep.c:724: warning: format ‘%08llx’ expects > type ‘long long unsigned int’, but argument 2 has type ‘CORE_ADDR’ > ../../gdb-6.8/gdb/or1k-tdep.c:732: warning: format ‘%08llx’ expects > type ‘long long unsigned int’, but argument 2 has type ‘CORE_ADDR’ > ../../gdb-6.8/gdb/or1k-tdep.c: In function ‘or1k_skip_prologue’: > ../../gdb-6.8/gdb/or1k-tdep.c:1374: warning: format ‘%08llx’ expects > type ‘long long unsigned int’, but argument 2 has type ‘CORE_ADDR’ > ../../gdb-6.8/gdb/or1k-tdep.c:1399: warning: format ‘%08llx’ expects > type ‘long long unsigned int’, but argument 2 has type ‘CORE_ADDR’ > ../../gdb-6.8/gdb/or1k-tdep.c:1413: warning: format ‘%08llx’ expects > type ‘long long unsigned int’, but argument 2 has type ‘CORE_ADDR’ > ../../gdb-6.8/gdb/or1k-tdep.c:1442: warning: format ‘%08llx’ expects > type ‘long long unsigned int’, but argument 2 has type ‘CORE_ADDR’ > ../../gdb-6.8/gdb/or1k-tdep.c:1475: warning: format ‘%08llx’ expects > type ‘long long unsigned int’, but argument 2 has type ‘CORE_ADDR’ > ../../gdb-6.8/gdb/or1k-tdep.c: In function ‘or1k_write_spr’: > ../../gdb-6.8/gdb/or1k-tdep.c:2854: warning: format ‘%8llx’ expects > type ‘long long unsigned int’, but argument 4 has type ‘long unsigned > int’ > ../../gdb-6.8/gdb/or1k-tdep.c: In function ‘or1k_info_spr_command’: > ../../gdb-6.8/gdb/or1k-tdep.c:2900: warning: format ‘%llu’ expects > type ‘long long unsigned int’, but argument 8 has type ‘long unsigned > int’ > ../../gdb-6.8/gdb/or1k-tdep.c:2900: warning: format ‘%llx’ expects > type ‘long long unsigned int’, but argument 9 has type ‘long unsigned > int’ > ../../gdb-6.8/gdb/or1k-tdep.c:2915: warning: format ‘%llu’ expects > type ‘long long unsigned int’, but argument 8 has type ‘long unsigned > int’ > ../../gdb-6.8/gdb/or1k-tdep.c:2915: warning: format ‘%llx’ expects > type ‘long long unsigned int’, but argument 9 has type ‘long unsigned > int’ > ../../gdb-6.8/gdb/or1k-tdep.c: In function ‘or1k_spr_command’: > ../../gdb-6.8/gdb/or1k-tdep.c:2972: warning: format ‘%llu’ expects > type ‘long long unsigned int’, but argument 8 has type ‘long unsigned > int’ > ../../gdb-6.8/gdb/or1k-tdep.c:2972: warning: format ‘%llx’ expects > type ‘long long unsigned int’, but argument 9 has type ‘long unsigned > int’ > ../../gdb-6.8/gdb/or1k-tdep.c:2972: warning: format ‘%llu’ expects > type ‘long long unsigned int’, but argument 10 has type ‘long unsigned > int’ > ../../gdb-6.8/gdb/or1k-tdep.c:2972: warning: format ‘%llx’ expects > type ‘long long unsigned int’, but argument 11 has type ‘long unsigned > int’ > make[2]: *** [or1k-tdep.o] Error 1 > make[2]: Leaving directory > `/home/xuebo/downloads/or1k_downloads/build_gdb/gdb' > make[1]: *** [all-gdb] Error 2 > make[1]: Leaving directory > `/home/xuebo/downloads/or1k_downloads/build_gdb' > make: *** [all] Error 2 > xuebo@ubuntu:~/downloads/or1k_downloads/build_gdb$ ls > > //------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ > > _______________________________________________ > http://www.opencores.org/mailman/listinfo/openrisc Tel: +44 (1202) 416955 Cell: +44 (7970) 676050 SkypeID: jeremybennett Email: jeremy.bennett@... Web: www.embecosm.com _______________________________________________ http://www.opencores.org/mailman/listinfo/openrisc |
|
|
Re: Errors occurred when building GDB using instuctions from EAN2 at www.embecosm.comHi Jeremy,
Thanks for you quickly response! I'll firstly try to build GDB using GCC 4.3.0 at Ubuntu, if fail, I'll mannually cast each type conversion in or1k-tdep.c. one more question, may I need firstly rebuild binutils and gcc (built using GCC 4.1.3) for OR32 before rebuild GDB using GCC 4.3.0? BR, Sigma HH 2009/2/27 Jeremy Bennett <jeremy.bennett@...>
_______________________________________________ http://www.opencores.org/mailman/listinfo/openrisc |
|
|
Re: Errors occurred when building GDB using instuctions from EAN2 at www.embecosm.comOn Fri, 2009-02-27 at 09:37 +0800, Sigma HH wrote:
> I'll firstly try to build GDB using GCC 4.3.0 at Ubuntu, if fail, I'll > mannually cast > each type conversion in or1k-tdep.c. > > one more question, may I need firstly rebuild binutils and gcc (built > using GCC 4.1.3) for OR32 before rebuild > GDB using GCC 4.3.0? Hi Sigma HH, No. It is GCC on the host, not the target that you are changing. ATB, Jeremy -- Tel: +44 (1202) 416955 Cell: +44 (7970) 676050 SkypeID: jeremybennett Email: jeremy.bennett@... Web: www.embecosm.com _______________________________________________ http://www.opencores.org/mailman/listinfo/openrisc |
| Free embeddable forum powered by Nabble | Forum Help |