[英]missing separator on Makefile
I am now having problems with a autotools generated Makefile, and it first looks like this . 我现在在使用自动工具生成的Makefile时遇到问题,它首先看起来像这样 。 When I was trying
make
an error arised: 当我尝试
make
错误出现时:
Makefile:327: *** missing separator. Stop.
Then, I tried the following change: 然后,我尝试了以下更改:
326,327c326
< LDFLAGS = -Wl,-O1,--sort-common,--as-needed,-z,relro -L/home/tjm/tmp/fake-root/libgd/usr/local/lib/ -L /home/tjm/tmp/fake-root/libpng/usr/local/lib -L /home/tjm/tmp/fake-root/freetype/usr/local/lib -L /home/tjm/tmp/fake-root/libpng/usr/local/lib -L /home/tjm/tmp/jpeg-6b
< -static
---
> LDFLAGS = -Wl,-O1,--sort-common,--as-needed,-z,relro -L/home/tjm/tmp/fake-root/libgd/usr/local/lib/ -L /home/tjm/tmp/fake-root/libpng/usr/local/lib -L /home/tjm/tmp/fake-root/freetype/usr/local/lib -L /home/tjm/tmp/fake-root/libpng/usr/local/lib -L /home/tjm/tmp/jpeg-6b -static
But, this time, I got this error: 但是,这次,我得到了这个错误:
Making all in intl
Makefile:35: *** missing separator. Stop.
make[1]: *** [Makefile:582: all-recursive] Error 1
make: *** [Makefile:489: all] Error 2
The related lines look like these: 相关行如下所示:
32 skip_next=no; \
33 strip_trailopt () \
34 { \
35 flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
36 }; \
And I teird a lot of things like: 我整理了很多东西,例如:
34 { flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; }; \
34 { \
35 flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; }; \
33 strip_trailopt () { flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; }; \
and 和
35 ^Iflg=printf '%s\n' "$$flg" | sed "s/$$1.*$$//"; \$
But still got the same error. 但是仍然出现相同的错误。
Does anyone can give me some ieda about how to fix it? 有谁能给我一些有关如何解决的想法?
(Note: I'm not sure if this is correct in StackOverflow vs SuperUser.) (注意:我不确定在StackOverflow和SuperUser中这是否正确。)
If you edited the Makefile
, it'll not be useful as it'll just re-generate out of Makefile.in
, and that one in turn will be generated out of Makefile.am
. 如果您编辑了
Makefile
,它将不再有用,因为它将仅从Makefile.in
重新生成,而该Makefile.in
又将从Makefile.am
。
Check your Makefile.am
file, and put -static
in the same line as everything else; 检查您的
Makefile.am
文件,并将-static
与其他所有文件放在同一行; what is happening is that it does not have a continuation symbol at the end of the previous line ( \\
), so the variable definition is not continued. 发生的情况是,在前一行(
\\
)的末尾没有连续符号,因此变量定义不再继续。 And because of that it tries to parse it as a rule, which it's not. 因此,它试图将其解析为规则,而不是规则。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.