Error in the building the Cross-Compiler: xgcc
Kai Ruottu
karuottu@freenet.hut.fi
Tue Jun 29 05:29:00 GMT 1999
Mzlai wrote:
> I am doing my cross-compiler for a embedded system.
>
> cd build-binutils
> ../binutils-2.9.1/configure --target=$target --prefix=$prefix
> make all install
>
> cd ../build-gcc
> ../egcs-1.1.2/configure --target=$target --prefix=$prefix
> --with-gnu-as --with-gnu-ld
> make cross install
>
> cd ../build-newlib
> ../newlib-1.8.1/configure --target=$target --prefix=$prefix
> make all install
>
> exit
>
> When I run the shell program , errors evoked. Maybe it was running
> in the second step----"make cross the egcs" when the error came.
> On the console,It prints:
>
> checking whether the C compiler (/home/tools/build-gcc/gcc/xgcc
> -B/home/tools/build-gcc/gcc/ -g )work.... no
> configure : error : installation or configuration problem:
> C compiler cannot create executables.
>
> then the program exited. I don't know where is the error happened and what
> is the reasons. Maybe the "xgcc" is the key of the problem!
>
> Ask for help from the all the experts!
This 'Catch-22' or 'Chicken and egg' -problem has been discussed many times
here, but perhaps it doesn't matter to talk about it again...
To make executables for the target one needs:
1. a working compiler -- you probably have it after getting the 'gcc' subdir
ready....
2. working libs and headers for the target -- you will have them after having
built newlib for the target...
So the 'newlib' and 'libgloss' subdirs can be tried to put into the egcs
source directory structure, so that it builds them before trying libiberty and
libstdc++. Or you can manually install what you already have, build newlib
with the installed 'arm-coff-gcc', install the C-library and continue with
egcs, now with a working C-library... Then it 'can create executables', the
default 'target board' seems to be the simulator with GDB...
Another possibility is to install some pre-built libs & headers (from newlib)
for arm-coff, like those of mine available via
www.nettilinja.fi/~ankosken/embtools.htm
and included inside the Cygwin-hosted/arm-coff-targeted toolset. Then build
egcs and try to build a better C-library for arm-coff... Especially I would
like to hear how one gets the output of doubles to work under arm-coff/elf:
---------------- clip -------------------
e-style >= 1: "1.234000e+01"
e-style >= .1: "1.234000e-01"
e-style < .1: "1.234000e-03"
e-style big: "0.0000000000002HJJ152IGKMHEKD2IGHFFLI1LJ1HEGGJLGIGLGJ1<IEGMGEIe
+20"
e-style == .1: "1.000000e-01"
f-style >= 1: "12.340000"
f-style >= .1: "0.123400"
f-style < .1: "0.001234"
g-style >= 1: "12.34"
g-style >= .1: "0.1234"
g-style < .1: "0.001234"
g-style big: "00000000000002HJJ152I.GKMHEKD2IGHFFLI1LJ1HEGGJLGIGLGJ1<IEGMGF"
0.10000
0.10000
x0.5000x
0x1
C.473:4559342121M:;e-39
C.473:4559342121M:;e-39
C.473:4559342121M:;e-39
C.473:4559342121M:;e-39
---------------- clip -------------------
instead of those HEKD, IGHFF, HEGG and GIGLG giggles.... (Perhaps I'll look at
this some day myself too...it may be just the simulator giving these)
Regards, Kai
_______________________________________________
New CrossGCC FAQ: http://www.objsw.com/CrossGCC
_______________________________________________
To remove yourself from the crossgcc list, send
mail to crossgcc-request@cygnus.com with the
text 'unsubscribe' (without the quotes) in the
body of the message.
More information about the crossgcc
mailing list