makefile的问题
我抄了一个makefile文件如下:文件名:makefile2#INCLUDEDIR = ../linux/include
INCLUDEDIR = /usr/src/linux/include
DEBFLAGS = -O2
CFLAGS = -D__KERNEL__ -DMODULE -Wall $(DEBFLAGS)
CFLAGS += -I$(INCLUDEDIR)
TARGET = hello
OBJS = $(TARGET).o
SRC = $(TARGET).c
all: $(TARGET).o
clean:
rm -f *.o *~ core
执行如下命令:
$ make -f makefile2
makefile2:17: *** missing separator.Stop.
什么原因呢?我觉得倒不是语法问题,肯定是一个莫名其妙的小问题 make use <tab> as the command start. so add a tab key before u rm -f... you are right
everything is ok now so go ahead to debug u code.
页:
[1]