This is the mail archive of the gcc-help@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: chicken-egg problem when building cross toolchain for linux


11.10.2013 14:27, Warlich, Christof kirjoitti:

as I need to build a couple of cross toolchains for various target architectures (powerpc, mipsel, i686 and arm, all running Linux with glibc), I'd like to generally understand how proceed. Most notably, I'd like to understand the proper sequence to do the job:

1) Configuring, building and installing cross binutils works fine.
2) But when I try to build a bootstrap gcc in the next step, it complains about missing libc header files.
3) Conversely, when I try to install the glibc headers first (make install-headers) , glibc configuration already fails as it does not find the cross compiler:

$ glibc/configure --prefix=3D$PREFIX --host=3D$TARGET --build=3Di686-pc-lin= ux-gnu ...
checking whether gcc -g -O2 -mlong-double-128 uses IBM extended format... n= o checking whether gcc -g -O2 supports -mabi=3Dibmlongdouble... no
configure: error: this configuration requires -mlong-double-128 IBM extende= d format support

Can anyone give me a hint on how to resolve this?


You just should understand how the capitalism or the evolutionary socialism works... For instance if one wants a car with Michelin tyres, instead of buying it without tyres at all and then driving with bare wheels to the Michelin tyre shop, one accepts using the "suitable but not right" Goodyears
coming with the car during the trip there.

So, be sure that there are freely downloadable glibcs for powerpc, mipsel, i686 and arm to be used
during the "bootstrap trip", when producing the target GCC and its libgcc :

make all-gcc
make all-target-libgcc

If only these will be required from the step-1 GCC. But of course one can build a complete one aimed for the existing powerpc, mipsel, i686 or arm Linux target system from which the glibc was
borrowed.

After GCC is ready, using it to build the "right" glibc from its sources is fully possible. Later one then uses the self-made toolchain components : binutils, glibc, GCC etc. when needing to update
one component like update the GCC part...

So the whole "from absolute scratch" idea is based on the Lenin, Trotski, Stalin etc. thoughts from the early 1900's for avoiding to use anything what the bad capitalism had created.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]