Re: PROBLEM: kernel 2.3.99-pre5 does not compile without system-wide kernel headers

From: Theodore Y. Ts'o (tytso@MIT.EDU)
Date: Thu Apr 20 2000 - 14:24:15 EST


   Date: Thu, 20 Apr 2000 06:59:31 -0400
   From: Jeff Garzik <jgarzik@mandrakesoft.com>

   Romain Vignes wrote:
> I have removed the kernel headers (/usr/include/linux and
> /usr/include/asm symlinks) from my Linux system. The goal is to compile
> multiple kernel versions without having to update the symlinks each
> time.

   The bug is in the process not in the kernel.

   1) You need headers in /usr/include/linux. For 2.3.x/2.4.x kernels it
   is generally assumed that the systemwide /usr/include/linux should be
   upgraded independently of the kernel includes.

.... except if you want to build stand-alone kernel modules that work
against the kernel that you are currently booting.

This still requires that /usr/include/linux and /usr/include/asm match
the kernel you are currently building. Some packages will now use
/usr/src/linux/include/{linux,asm} in preference if they exist, or allow
the user to manually specify the location of the kernel source tree to
use, but these conventions haven't been universally standardized yet.

Doing so would be a good idea, BTW. If we can all agree that "this is
the way to do things in Linux 2.4", and make sure all of the
distributions are informed of that fact, that would be Good Thing (tm).
My personal nomination of the standard way to do things is to assume
that /usr/src/linux is a symlink to kernel sources corresponding to the
default kernel being booted on that machine, and that stand-alone device
drivers that need to compile against a kernel should default to
/usr/src/linux, but there should be an easy way for users to override
that and specify some other kernel source tree if necessary. Any
objections to such an approach?

                                                - Ted

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Sun Apr 23 2000 - 21:00:17 EST