On 12/1/05, Mark Rosenstand <[EMAIL PROTECTED]> wrote:
> I would like it to use inotify, but it doesn't because the headers are
> too old. I never really understood why most (all?) distributors choose
> to use kernel headers that doesn't match the running kernel.

It's up to the userspace package you're installing to include the
appropriate headers for inotify support.  The userspace package cannot
make any assumptions about what kernel you're running or what kernel
your libc is compiled against.  That would be insane.

Now, as for not installing the kernel headers of your running kernel,
this has been hashed out MANY times.  Once more though...

When you install glibc, it is built against a static headers package
(linux-libc-headers or you could pull the headers from a kernel source
tree, but they're not sanitized).  After you install glibc, you can't
blindly update the headers because then any application you compile
using libc functions (probably every single one) would see different
function definitions than actually exist in your libc.

Say you put the 2.6.14 headers in /usr/include but your libc was
installed against 2.6.12.  Now, you compile a program that wants
inotify support.  It finds the appropriate definitions in
/usr/include/linux/some-header.h.  Assuming it builds, when you run
your program and it makes a call to some glibc function that the
2.6.14 headers say will return some inotify result, you get an error. 
See how that works?  That's why it's called linux-libc-headers.

If you don't believe me, read this old thread:
http://linuxfromscratch.org/pipermail/faq/2004-July/000159.html
and in Linus' own words:
http://linuxmafia.com/faq/Kernel/usr-src-linux-symlink.html

--
Dan
--
http://linuxfromscratch.org/mailman/listinfo/lfs-dev
FAQ: http://www.linuxfromscratch.org/faq/
Unsubscribe: See the above information page

Reply via email to