On Tuesday 21 July 2009 15:39:57 Denys Vlasenko wrote: > On Tuesday 21 July 2009 18:59, Ron wrote: > > On Tue, Jul 21, 2009 at 06:17:02PM +0200, Denys Vlasenko wrote: > > > On Tue, Jul 21, 2009 at 5:31 PM, Bernhard Reutner-Fischer wrote: > > > > Mike removed it since it's not libc's business to install kernel > > > > headers (and i agree with him, fwiw). > > > > I'll agree with that too while we're at it :) > > > > > Ok, then how can I test uclibc _before_ I install it? > > > I can build it becuase I have correctly set up KERNEL_HEADERS="xxx", > > > but "make check" does not work. > > > > > > > You have to have a properly installed set of kernel-headers before > > > > you build the libc, really. > > > > > > This adds yet another step into cross-compilation. > > > > That step was always there if you want to bootstrap everything from > > source. > > > > > Up to today, I was able to: > > > 1. build+install cross-compiling toolchain, > > > > You can't do that without lk headers and at least a 'bootstrap' build of > > the C lib headers. > > I did it several times for a few architectures. It works. > Somewhat limited toolchain can be built for an architecture > without kernel/libc headers. For gcc, you'd need to configure it > with --enable-languages="c,c++" --without-headers --with-newlib.
working for *some* arches and for *some* kernel versions is not the same thing as *all*. some arches (like ia64) have never worked with --without-headers while others sometimes work. in either case, the option is not supported by gcc. this is why we have a headers-only install target (and glibc has a similar target, but theirs tends to be broken due to drepper's stance on cross-compiling). it also means you need to build the cross-compiler twice. the first one (built without headers) will have broken handling exception handling and will not support sysroot. it will only be able to build a kernel and the C library. ive documented all of this a while ago: http://embedded.gentoo.org/handbook/?part=1&chap=4#doc_chap3 > > You might be able to 'cheat' and start from some > > package someone else made, but _someone_ needs to provide this before you > > can build a working toolchain. This isn't step 1. > > > > > 2. build+install uclibc, > > > > ... so you should already have them by the time you get to this point. > > I built uclibc many times without kernel headers installed > in $sysroot, I just need to point KERNEL_HEADERS to whereever they are. and that still works. his point was that to build gcc with headers, you would have needed the kernel and C library headers installed. > "make check" does not respect KERNEL_HEADERS. > I don't know how to put it simpler than that. i'm not sure it should, but i wouldnt care much either way. it should be trivial to add. -mike
signature.asc
Description: This is a digitally signed message part.
_______________________________________________ uClibc mailing list [email protected] http://lists.busybox.net/mailman/listinfo/uclibc
