using glibc headers to build bootstrap gcc?

Ralf Corsepius
Tue Oct 4 15:55:00 GMT 2005

On Tue, 2005-10-04 at 11:36 -0400, Robert P. J. Day wrote:
>   there appear to be at least three different variations for how to
> use the glibc headers to build the bootstrap gcc phase of the
> toolchain.
>   first, yaghmour's book orders the phases of the build so that the
> bootstrap compiler is done before *any* of the glibc stuff.  because
> of that, his bootstrap configuration uses the option
> "--without-headers".
That's a band-aid to getting started bootstrapping, but a functional GCC.

>   if you have already installed the glibc headers, though, another
> approach seems to be using a
> variation of "--with-headers=${SYSROOT}/usr/include".
>   and crosstool takes yet another approach, using the config option
> "--with-local-prefix=", which i'm going to guess subsumes
> --with-headers=.
>   are there substantial differences in the ultimate effect of using
> one or the other of the above?
Yes, a GCC having been built with --without-headers is not a fully
functional GCC. It uses hard-coded assumptions on libc's capability and
does not reflect your actual setup. Normally it's only build for

It's meant to be a band-aid to break the vicious build dependency circle
between GCC and libc, when bootstrapping GCC+libc from scratch.

--with-local-prefix is something completely different. It can be used to
redirect /usr/local/{lib|include}. IIRC, GCC automatically switches it
off for cross compilers, because it's normally not "that useful" for


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

More information about the crossgcc mailing list