0

I'm trying to cross compile BINUTILS to i386-elf and I'm getting the following error.

At the end of the ouput...

        -c -o printcmd.o -MT printcmd.o -MMD -MP -MF .deps/printcmd.Tpo ../../binutils-2.24.51-4/gdb/printcmd.c
gcc -g -O2   -I. -I../../binutils-2.24.51-4/gdb -I../../binutils-2.24.51-4/gdb/common -I../../binutils-2.24.51-4/gdb/config -DLOCALEDIR="\"/home/bruno/opt/cross/share/locale\"" -DHAVE_CONFIG_H -I../../binutils-2.24.51-4/gdb/../include/opcode -I../../binutils-2.24.51-4/gdb/../opcodes/.. -I../../binutils-2.24.51-4/gdb/../readline/.. -I../bfd -I../../binutils-2.24.51-4/gdb/../bfd -I../../binutils-2.24.51-4/gdb/../include -I../libdecnumber -I../../binutils-2.24.51-4/gdb/../libdecnumber  -I../../binutils-2.24.51-4/gdb/gnulib/import -Ibuild-gnulib/import    -Wall -Wdeclaration-after-statement -Wpointer-arith -Wpointer-sign -Wno-unused -Wunused-value -Wunused-function -Wno-switch -Wno-char-subscripts -Wmissing-prototypes -Wdeclaration-after-statement -Wempty-body -Wmissing-parameter-type -Wold-style-declaration -Wold-style-definition -Wformat-nonliteral  -c -o block.o -MT block.o -MMD -MP -MF .deps/block.Tpo ../../binutils-2.24.51-4/gdb/block.c
gcc -g -O2   -I. -I../../binutils-2.24.51-4/gdb -I../../binutils-2.24.51-4/gdb/common -I../../binutils-2.24.51-4/gdb/config -DLOCALEDIR="\"/home/bruno/opt/cross/share/locale\"" -DHAVE_CONFIG_H -I../../binutils-2.24.51-4/gdb/../include/opcode -I../../binutils-2.24.51-4/gdb/../opcodes/.. -I../../binutils-2.24.51-4/gdb/../readline/.. -I../bfd -I../../binutils-2.24.51-4/gdb/../bfd -I../../binutils-2.24.51-4/gdb/../include -I../libdecnumber -I../../binutils-2.24.51-4/gdb/../libdecnumber  -I../../binutils-2.24.51-4/gdb/gnulib/import -Ibuild-gnulib/import    -Wall -Wdeclaration-after-statement -Wpointer-arith -Wpointer-sign -Wno-unused -Wunused-value -Wunused-function -Wno-switch -Wno-char-subscripts -Wmissing-prototypes -Wdeclaration-after-statement -Wempty-body -Wmissing-parameter-type -Wold-style-declaration -Wold-style-definition -Wformat-nonliteral  -c -o symtab.o -MT symtab.o -MMD -MP -MF .deps/symtab.Tpo ../../binutils-2.24.51-4/gdb/symtab.c
../../binutils-2.24.51-4/gdb/symtab.c: In function ‘symbol_find_demangled_name’:
../../binutils-2.24.51-4/gdb/symtab.c:667:7: error: ‘LINKER_SYMBOLS_HAVE_WIN32_STDCALL_ARG_SIZES’ undeclared (first use in this function)
   if (LINKER_SYMBOLS_HAVE_WIN32_STDCALL_ARG_SIZES)
       ^
../../binutils-2.24.51-4/gdb/symtab.c:667:7: note: each undeclared identifier is reported only once for each function it appears in
make[2]: *** [symtab.o] Error 1
make[2]: se sale del directorio «/home/bruno/src/build-binutils/gdb»
make[1]: *** [all-gdb] Error 2
make[1]: se sale del directorio «/home/bruno/src/build-binutils»
make: *** [all] Error 2

Any ideas? Thank you very much!

bgarate
  • 116
  • 2
  • 9

1 Answers1

0

What i did, and i hope i'm right, was to define LINKER_SYMBOLS_HAVE_WIN32_STDCALL_ARG_SIZES as (0) in symtab.c. I think the constant is used when you are running it in CYGWING.

And it compiled, now I expect it to work just fine.

bgarate
  • 116
  • 2
  • 9