michile

导航

makefile

ifeq ($(KERNELRELEASE),)

 

KERNELDIR ?= /source/linux-2.6.8.1

PWD := $(shell pwd)

 

modules:

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

 

modules_install:

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

 

clean:

         rm -rf *.o *~ core .depend .*.cmd *.ko *.mod.c .tmp_versions

 

.PHONY: modules modules_install clean

 

else

    obj-m := hello.o

endif

posted on 2013-02-17 17:54  michile  阅读(152)  评论(0编辑  收藏  举报