Re: insmod segfault in pci_find_subsys()

From: Sam Ravnborg
Date: Wed Apr 13 2005 - 08:29:21 EST


On Wed, Apr 13, 2005 at 01:49:10PM +0200, Toralf Lund wrote:
> >
> >
> Yes. As I've (also) already said elsewhere, I knew that, really. The
> current build setup fails to do this partly for historical reasons,
> partly because the driver also supports different OSes. (And is still
> expected to build correctly with Linux 2.4, not just 2.6.)

Following trick works with both 2.4 and 2.6:

makefile:
all:
$(MAKE) -C Kernel_src_path SUBDIRS=$(PWD) modules

Makefile:

obj-m := mymodule.o

It obtains CFLAGS as expected etc.
People seems to do their best to avoid such a simple setup :-(

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