I am using the latest stable Linux from Scratch book version. In Step 5.5.1, when configuring Glibc I run the provided script, and receive an error telling me to use the --with-headers configure option, however I am already using it.

The book states to configure using:

../configure \ --prefix=/usr \ --host=$LFS_TGT \ --build=$(../scripts/config.guess) \ --enable-kernel=3.2 \ --with-headers=$LFS/usr/include \ libc_cv_slibdir=/lib

When doing so I receive the following error:

checking installed Linux kernel header files... missing or too old!
configure: error: GNU libc requires kernel header files from
Linux 3.2.0 or later to be installed before configuring.
The kernel header files are found usually in /usr/include/asm and
/usr/include/linux; make sure these directories use files from
Linux 3.2.0 or later.  This check uses <linux/version.h>, so
make sure that file was built correctly when installing the kernel header
files.  To use kernel headers not from /usr/include/linux, use the
configure option --with-headers.

Any advise on how to proceed would be much appreciated.

1 Answer 1


Resolved. Simple error on my part. In case someone else runs into this in the future: In the previous step (5.4.1) there may have been an error in the installation of the Linux headers, and to run "cp -rv usr/include $LFS/usr" root may be required. In my case I must have missed this specific command, thus in the next step there were simply no headers for glibc to work with.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .