| Building NPTL-capable toolchains |
|
|
|
This page describes a script I've cobbled together from various sources, that allows me
to build a cross-compiling toolchain (binutils, gcc, glibc) that are NPTL (Native Posix
Threading Library) capable, running on Fedora Core 3.
This is mostly a staging area until I take a look at crosstool and see how this can
be integrate there. Hopefully, I'll actually get around to doing that!
Some caveats:
- I've only run this on Fedora Core 3. It should work elsewhere, but it's not tested.
- I've used hard-coded binutils/gcc/glibc versions. It certainly won't work out of the
box for other combinations, because it only has patches for this specific combination.
crosstool contains a repository of useful
patches. Hopefully, I'll get around to looking at how to integrate this into crosstool
one day.
- The resultant PPC toolchain has been used to build simple pthreads test applications,
and these do run on real hardware (a MontaVista 3.1 system, where I replaced the provided
glibc with the one built here, and ran the test app). The x86 toolchain has not been
tested at all.
To use this, create a working directory (same ~/nptltool). Put all the scripts from the list
below in a sub-directory of that directory named "downloads". Then, make sure you have
downloaded the source to binutils, glibc, gcc & the kernel into downloads. Finally, read
and then run nptl_build.sh, and wait.
Files you can download from here:
Files you'll need to download from elsewhere:
binutils-2.15.tar.gz
config-i686-unknown-linux-gnu (a .config file for the kernel)
config-powerpc-unknown-linux-gnu (a .config file for the kernel)
gcc-3.4.3.tar.bz2
glibc-2.3.3.tar.bz2
glibc-linuxthreads-2.3.3.tar.bz2
linux-2.6.11.tar.bz2
|