Jump to content

Kernel module Makefile [solved]


Recommended Posts

I have written a char device driver and with the makefile;

 

ifneq ($(KERNELRELEASE),)

obj-m := lunix2k5.o

else

KERNELDIR ?=/lib/modules/$(shell uname -r)/build

PWD := $(shell pwd)

default:

$(MAKE) -C $(KERNELDIR) M=$(PWD) modules

endif

 

I could see it working in both Suse 9.2 and FC3.

 

 

However when I use make in Mandrake 10.1 I get the following;

 

make -C /lib/modules/2.6.8.1-10mdk M=/home/pani/lunix modules

make[1]: Entering directory `/lib/modules/2.6.8.1-10mdk'

make[1]: *** No rule to make target `modules'. Stop.

make[1]: Leaving directory `/lib/modules/2.6.8.1-10mdk'

make: *** [default] Error 2

 

What should I change?

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...