📄 makefile
字号:
## Makefile for the Linux Philips USB Webcam driver## NOTE: This make file can serve as both an external Makefile (launched# directly by the user), or as the sub-dir Makefile used by the kernel# build system.# If CONFIG_USB_PWC isn't set, we'll assume the user want to build this driver has a moduleifndef CONFIG_USB_PWCCONFIG_USB_PWC=m# Comment the next line, if you don't want debug message and a smaller binaryCONFIG_PWC_DEBUG=yendififneq ($(KERNELRELEASE),)pwc-objs := pwc-if.o pwc-misc.o pwc-ctrl.o pwc-v4l.o pwc-uncompress.opwc-objs += pwc-dec1.o pwc-dec23.o pwc-kiara.o pwc-timon.oobj-$(CONFIG_USB_PWC) += pwc.oEXTRA_CFLAGS=-Wall -I$(PWD)ifeq ($(CONFIG_PWC_DEBUG),y)EXTRA_CFLAGS += -DCONFIG_PWC_DEBUG=1elseEXTRA_CFLAGS += -DCONFIG_PWC_DEBUG=0endifelseKVER := $(shell uname -r)KLINK := $(shell test -e /lib/modules/${KVER}/source/ && echo source || echo "build")KSRC := /lib/modules/$(KVER)/$(KLINK)KMISC := /lib/modules/$(KVER)/kernel/drivers/usb/mediaPWD := $(shell pwd)# Fix some problem with suse < 9.2 and suse >= 9.2is_suse := $(shell test -e /etc/SuSE-release && echo 1 || echo 0)ifeq ($(is_suse),1) suse_version := $(shell grep VERSION /etc/SuSE-release | cut -f 3 -d " "| tr -d .) is_suse_92_or_greater := $(shell test $(suse_version) -ge 92 && echo 1) ifeq ($(is_suse_92_or_greater),1) KSRC := /lib/modules/$(KVER)/build endifendifall default: $(MAKE) -C $(KSRC) SUBDIRS=$(PWD) modulesinstall: default install -d $(KMISC) install -m 644 -c pwc.ko $(KMISC) -/sbin/depmod -auninstall: -rm -rf $(KMISC)/pwc.koendifclean: rm -f *.[oas] .*.flags *.ko .*.cmd .*.d .*.tmp *.mod.c rm -rf .tmp_versions
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -