Re: Red Hat 6.1 version.h modifications

Miquel van Smoorenburg (miquels@cistron.nl)
10 Oct 1999 20:01:32 +0200


In article <cistron.Pine.LNX.4.10.9910091501330.22383-100000@labyrinth>,
Edward S. Marshall <emarshal@logic.net> wrote:
>On Sat, 9 Oct 1999, Olaf Titz wrote:
>> Just address the issue of compiling for a different kernel than that
>> which currently runs.
>
>Easy. Place the makefile fragment with the modules that are created for
>that kernel (/lib/modules/<version>/kernel.mk or some such), and ensure
>that there is enough path information stored in that fragment to build a
>kernel based on it (ie. such that the builder can find the original
>sources that it was generated from, for the necessary header files).

Why not simply place the Makefile fragment in /usr/src/linux/include.
You could then write module Makefiles like this:

# Point to the kernel you're building for
KERNEL = /usr/src/linux-2.5.1

include $(KERNEL)/options.mak

CFLAGS := -I$(KERNEL)/include $(CFLAGS)

... et voila

Mike.

-- 
First things first, but not necessarily in that order.

- 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/