现在直接在内核添加一模块,在编译时出现问题,
make: *** 空变量名。 停止。
make: *** [modules] 错误2
附上部分Makefile:
CROSS_COMPILE = arm-linux-gcc-4.3.2
ARCH = arm
KERNELDIR = KBUILD ?= $(shell readlink -f /lib/modules/$(KVERS)/build)
#PWD = $(shell pwd)
# Add your debugging flag (or not) to CFLAGS
ifeq ($(DEBUG),y)
DEBFLAGS = -O -g -DSCULL_DEBUG -Wall # "-O" is needed to expand inlines
else
DEBFLAGS = -O -Wall #-O2
endif
modules:
$(MAKE) -C $(KERNELDIR) M=$(PWD) ARCH=$(ARCH) CROSS_COMPILE=$(CROSS_COMPILE) LDDINC=$(PWD)/../include modules
由于这是例程,有点没读懂,希望大家能帮忙指点一下。先谢谢各位了。
[ 此帖被戼逇在2010-11-18 15:22重新编辑 ]