AW: Canadian cross build fails

Titus von Boxberg titus@elbe-informatik.de
Mon Feb 9 13:07:00 GMT 2015


Hi,

I had the same issue (with canadian for powerpc iirc).

If you look into the source file causing the error you see a comment similar to "XXX fixme" or so.

So the problem is known but a "real solution" is not at hand.
Thus, I have patched the definition of caddr_t away and it works for me.

Regards,
Titus


-----Ursprüngliche Nachricht-----
Von: crossgcc-owner@sourceware.org [mailto:crossgcc-owner@sourceware.org] Im Auftrag von Matthias Weißer
Gesendet: Montag, 9. Februar 2015 13:25
An: crossgcc@sourceware.org
Betreff: Canadian cross build fails

 [INFO ]  Installing final compiler for build: done in 223.82s (at 22:21) [INFO ]  =================================================================
[INFO ]  Installing final compiler
[EXTRA]    Configuring gcc
[EXTRA]    Building libiberty
[EXTRA]    Building gcc
[ALL  ]    arm-gs-linux-gnueabihf-cc   -mlittle-endian -march=armv7-a
-mcpu=cortex-a9 -mtune=cortex-a9 -mfpu=vfpv3 -mhard-float -O2 -mlittle-endian -march=armv7-a  -mcpu=cortex-a9 -mtune=cortex-a9
-mfpu=vfpv3 -mhard-float  -DIN_GCC  -DCROSS_DIRECTORY_STRUCTU RE  -W -Wall -Wno-narrowing -Wwrite-strings -Wcast-qual -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -isystem ./include  -I. -I. -I../.././gcc -I/$LONGPATH/.build/src/gcc-4.9.2/libgcc
-I/$LONGPATH/.build/src/gcc-4.9.2/libgcc/.
-I/$LONGPATH/.build/src/gcc-4.9.2/libgcc/../gcc
-I/$LONGPATH/.build/src/gcc-4.9.2/libgcc/../include   -g0
-finhibit-size-directive -fno-inline -fno-exceptions -fno-zero-initialized-in-bss -fno-toplevel-reorder -fno-tree-vectorize -fno-stack-protector  -I. -I. -I../.././gcc -I/$LONGPATH/.build/src/gcc-4.9.2/libgcc
-I/$LONGPATH/.build/src/gcc-4.9.2/libgcc/.
-I/$LONGPATH/.build/src/gcc-4.9.2/libgcc/../gcc
-I/$LONGPATH/.build/src/gcc-4.9.2/libgcc/../include  -o crtendS.o -MT crtendS.o -MD -MP -MF crtendS.dep  -fPIC -c /$LONGPATH/.build/src/gcc-4.9.2/libgcc/crtstuff.c -DCRT_END -DCRTSTUFFS_O
[ALL  ]    In file included from
/$LONGPATH/.build/src/gcc-4.9.2/libgcc/crtstuff.c:54:0:
[ERROR]    ../.././gcc/auto-host.h:1996:17: error: two or more data
types in declaration specifiers
[ALL  ]     #define caddr_t char *
[ALL  ]                     ^
[ALL  ]    In file included from
/$LONGPATH/.build/src/gcc-4.9.2/libgcc/../gcc/tsystem.h:90:0,
[ALL  ]                     from
/$LONGPATH/.build/src/gcc-4.9.2/libgcc/crtstuff.c:60:
[ERROR]    /$LONGPATH/output/arm-gs-linux-gnueabihf/sysroot/usr/include/sys/types.h:116:26:
error: expected identifier or '(' before ';' token
[ALL  ]     typedef __caddr_t caddr_t;
[ALL  ]                              ^

If I check google for that error I come across the following pages:
https://sourceware.org/ml/newlib/2014/msg00034.html
http://www.gurucoding.com/en/pc_cross_compiler/building_binutils_gcc_mingw_vm.php


Both suggest patching gcc autoconf or the C library itself. I can't belive that this is the correct solution to this issue. Do I miss something? What is a bit unclear to me is that I don't have to (or I missed it) specify the path to the toolchain build in step 1 to the canadian build in step 3. I do pass the toolchain from step 2 into the crosstools config as host. This is my mini-defconfig of the step 3
toolchain:




More information about the crossgcc mailing list