GNU make yield“命令在第一个目标之前开始”错误 [英] GNU make yields “commands commence before first target” error
问题描述
尝试从Fedora 15 x86_64上的源安装Emacs 22.3。
Trying to install Emacs 22.3 from sources on Fedora 15 x86_64.
./configure
命令正常,但
使收益率错误:
[sigrlami@server emacs-22.3]# make
cd lib-src; make all \
CC='gcc' CFLAGS='-g -O2 -Wno-pointer-sign ' CPPFLAGS='-D_BSD_SOURCE ' \
LDFLAGS='-Wl,-znocombreloc ' MAKE='make'
make[1]: Entering directory `/home/sigrlami/bin/emacs-22.3/lib-src'
Makefile:148: *** recipe commences before first target. Stop.
make[1]: Leaving directory `/home/sigrlami/bin/emacs-22.3/lib-src'
make: *** [lib-src] Error 2
在makefile中,我没有触摸任何东西,一切似乎都在第148行:
In makefile, where I don't touch anything, everything seems ok in row 148:
144 # ========================== start of cpp stuff =======================
145 LIBS_MOVE=$(KRB4LIB) $(DESLIB) $(KRB5LIB) $(CRYPTOLIB) $(COM_ERRLIB) $(HESIODLIB)
146 LOADLIBES= -lc
147 ALL_CFLAGS = -D_BSD_SOURCE -DHAVE_CONFIG_H
148 -I. -I../src -I${srcdir} -I${srcdir}/../src ${LDFLAGS} ${CPPFLAGS} ${CFLAGS}
149 LINK_CFLAGS = -D_BSD_SOURCE -DHAVE_CONFIG_H
有什么建议如何解决这个问题?可能系统没有一些库?
Any suggestions how to fix this? Maybe system doesn't have some libraries?
推荐答案
make输入语言是白色空间敏感的。
The make input language is white-space sensitive.
特定的命令(为了重新制作目标而要运行的动作)从一个选项卡开始,所以这个错误明确地告诉你,你的标签不合适。
In particular commands (actions to be run in order to remake targets) begin with a tab, so the error is telling you unambiguously that you have a tab out of place.
尽管只有具有特殊意义的行开头的选项卡,我尝试不使用makefile中的任何标签,而不是信号开始的命令。
While it is only tabs at the beginning of lines that have the special significance, I try to not use any tabs in my makefiles other than that the signal the beginning of commands.
这篇关于GNU make yield“命令在第一个目标之前开始”错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!