makefile:缺少分隔符 [英] makefile : missing separator
本文介绍了makefile:缺少分隔符的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
#kernel build system and can use its lanauge
ifneq($(KERNELRELEASE),)
obj-m:=helloworld.o
else
KDIR:= /lib/modules/2.6.33.3-85.fc13.i686/build
all:
make -C $(KDIR) M=$(PWD) modules
clean:
rm -f *.ko *.o *.mod.o *.mod.c *.symvers
endif
错误是:
makefile:2:***缺少分隔符.停止
但是对于ifneq($(KERNELRELEASE),)
,如果我之前添加了标签页,则会收到另一个错误:
makefile:2:***命令在第一个目标之前开始.停止
解决方案
ifneq
和(
之间必须有一个空格.
TAB前缀意味着它是一个Shell命令,因此请确保Shell命令(make
和rm
)以TAB开头,而所有其他行(例如ifneq
)都不以TAB开头. /p>
#kernel build system and can use its lanauge
ifneq($(KERNELRELEASE),)
obj-m:=helloworld.o
else
KDIR:= /lib/modules/2.6.33.3-85.fc13.i686/build
all:
make -C $(KDIR) M=$(PWD) modules
clean:
rm -f *.ko *.o *.mod.o *.mod.c *.symvers
endif
The error is:
makefile:2:*** missing separator . stop
but for the ifneq($(KERNELRELEASE),)
, if I add a tab before, I get another error:
makefile:2: ***commands commence before first target. stop
解决方案
There must be a space between ifneq
and (
.
The TAB prefix means that it is a shell command, so be sure that the shell commands (make
and rm
) begin with TAB, and all other lines such as ifneq
do not begin with TAB.
这篇关于makefile:缺少分隔符的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文