glibc-2.2.5 build problem on Cygwin : target i386-linux

Kai Ruottu
Fri Apr 4 12:53:00 GMT 2003

babu wrote:

> We are in the process of building a crossgcc for "i386-linux" on cygwin.
> Following are ok:
>  - binutils-2.12
>  - gccbootstrap - 2.95.4
> while compiling the glibc-2.2.5,

  The normal method is to copy the already built glibc-2.2.5 from the
target, then build GCC against it. No delimited 'bootstrap-GCC', but
the fully working GCC immediately...

  So, why you desperately are trying to build glibc-2.2.5 with a probably
non-working GCC ?  Building GCC and glibc reguires a working compiler, 
in the usual 'newbie' meaning, not in the GCC meaning.

> with the following configuration, we are getting the errors attached.
 > If you have come across this issue, please let us know what is
 >  missing :
>                 CC=i386-linux ./configure \
>                 host=i386-linux \
>                 build=i386-linux \
>                 --enable-add-ons="linuxthreads" \
>                 --with-headers=${KERNEL_DIR}/include/

  This expects you having a working GCC, and this you will get if 
building your GCC against the Linux-headers, ie. using 'suitable'
ones, just as the GCC manual advices. You should follow the rules
told there and not try any workarounds. Linux/x86 headers should
be available easily... With 'suitable' headers you will get a
working 'libgcc.a' with working exception handling, threads support
and whatever the GCC build tries to put there.

> /sys/build_tools/glibc-2.2.5/build-i386-linux/posix/getconf.o: In function
> `usage':
> /sys/build_tools/glibc-2.2.5/posix/getconf.c:885: undefined reference to `exit'
> /sys/build_tools/glibc-2.2.5/build-i386-linux/ undefined reference
> to `__dup'
> /sys/build_tools/glibc-2.2.5/build-i386-linux/ undefined reference
> to `__strtod_internal'

  My advice to you is to copy a prebuilt glibc-2.2.5 from a RedHat 7.3,
Suse 8.0 etc. which use it. Then build your GCC against it and maybe
build your own glibc-2.2.5, if necessary --- what I will strongly
suspect...  Anyway, when using a working GCC (please test with all
kind of "Hello World's", linked against the copied glibc, before
starting to build your own glibc-2.2.5), the build should succeed...

  The next time someone suggest to use diesel oil in your car aimed
for benzin, don't believe!  Currently there are instructions which
suggest one to use newlib when building a GCC for Linux, and these
are just equivalent to the diesel/benzin issue...

Cheers, Kai

Want more information?  See the CrossGCC FAQ,
Want to unsubscribe? Send a note to

More information about the crossgcc mailing list