I'm cross-compiling Linux for a 386. If you just scoffed at reading that, then let me tell you that (1) of all the purported "i386" distros not a single one runs on a real 386 (caveats galore - see Q4), and (2) the questions have more to do with glibc, NPTL, and LinuxThreads than Linux and 386s.
I'm using the LFS LiveCD <http://www.linuxfromscratch.org/livecd/download.html> in conjunction with CLFS's instructions for 32-bit x86s <http://cross-lfs.org/view/1.0.0/>. I'm building under Virtual PC so I can clean up mistakes quickly, but I will make the final build on a P4 Northwood. All goes well until the time comes to build glibc 2.4... Question 0: What specifically is it about NPTL that prevents it from being compiled for a 386? Question 1: When I ignore NPTL's animosity towards targeting 386s, the `make` fails with the following: In file included from ../nptl/sysdeps/unix/sysv/linux/libc-lowlevellock.c:21: ../nptl/sysdeps/unix/sysv/linux/lowlevellock.c:29: error: conflicting types for '__lll_lock_wait' ../nptl/sysdeps/unix/sysv/linux/i386/lowlevellock.h:361: error: previous declaration of '__lll_lock_wait' was here ../nptl/sysdeps/unix/sysv/linux/lowlevellock.c: In function '__lll_lock_wait': ../nptl/sysdeps/unix/sysv/linux/lowlevellock.c:32: warning: implicit declaration of function 'atomic_compare_and_exchange_val_acq' ../nptl/sysdeps/unix/sysv/linux/lowlevellock.c:36: warning: implicit declaration of function 'atomic_compare_and_exchange_bool_acq' ../nptl/sysdeps/unix/sysv/linux/lowlevellock.c: At top level: ../nptl/sysdeps/unix/sysv/linux/lowlevellock.c:42: warning: no previous prototype for '__lll_timedlock_wait' make[2]: *** [/mnt/clfs/sources/glibc-build/nptl/libc-lowlevellock.o] Error 1 make[2]: Leaving directory `/mnt/clfs/sources/glibc-2.4/nptl' make[1]: *** [nptl/subdir_lib] Error 2 make[1]: Leaving directory `/mnt/clfs/sources/glibc-2.4' make: *** [all] Error 2 How might I go about resolving the "___lll_lock_wait" conflict? Question 2: I grabbed glibc-linuxthreads-2.5.tar.bz2 from <http://ftp.gnu.org/gnu/glibc/> and changed the glibc configuration flags accordingly. When it comes to time to `make`, I get the following: memusage.c:748: warning: type defaults to 'int' in declaration of '__gnewval' memusage.c:748: error: invalid type argument of 'unary *' memusage.c:748: error: invalid type argument of 'unary *' memusage.c:748: warning: left-hand operand of comma expression has no effect memusage.c: In function 'dest': memusage.c:773: error: 'buffer_cnt' undeclared (first use in this function) memusage.c:778: error: 'peak_use' undeclared (first use in this function) memusage.c:800: error: 'grand_total' undeclared (first use in this function) memusage.c:802: error: 'calls' undeclared (first use in this function) memusage.c:803: error: 'total' undeclared (first use in this function) memusage.c:804: error: 'failed' undeclared (first use in this function) memusage.c:810: error: 'inplace' undeclared (first use in this function) memusage.c:810: error: 'decreasing' undeclared (first use in this function) memusage.c:841: error: 'inplace_mremap' undeclared (first use in this function) memusage.c:842: error: 'decreasing_mremap' undeclared (first use in this function) memusage.c:852: error: 'large' undeclared (first use in this function) memusage.c:854: error: 'histogram' undeclared (first use in this function) memusage.c:861: error: 'calls_total' undeclared (first use in this function) make[2]: *** [/mnt/clfs/sources/glibc-build/malloc/memusage.os] Error 1 make[2]: Leaving directory `/mnt/clfs/sources/glibc-2.4/malloc' make[1]: *** [malloc/others] Error 2 make[1]: Leaving directory `/mnt/clfs/sources/glibc-2.4' make: *** [all] Error 2 How would I go about resolving the memusage.os's conniptions? Question 3: If neither NPTL or LinuxThreads will work, then what can I use as a substitute? Question 4: If all else fails, can someone name a recent (<2 years) Linux distro that runs on a 386, has math-emulation built into the kernel, whose kernel and boot image sizes are less than 8MB in total, uses LOADLIN.EXE to start up (Grub and Lilo *cannot* be used), and will install to USB-connected CF card? - NeoAmsterdam -- http://linuxfromscratch.org/mailman/listinfo/lfs-support FAQ: http://www.linuxfromscratch.org/lfs/faq.html Unsubscribe: See the above information page