CC = gcc PWD := $(shell pwd) KVER := $(shell uname -r) KDIR := /lib/modules/$(KVER)/build obj-m := rtk_btusb.o all: $(MAKE) -C $(KDIR) M=$(PWD) modules install: all make -C $(PWD) -s cp -f $(PWD)/rtk_btusb.ko $(KDIR)/rtk_btusb.ko depmod -a $(KDIR) clean: rm -rf *.o *.mod.c *.mod.o *.ko *.symvers *.order *.a