当我尝试在makefile上运行“make all”时遇到一些复杂性我得到了这个错误:
C:\BITCLOUD\BitCloud_PS_SAM3S_EK_1_10_0\BitCloud_PS_SAM3S_EK_1_10_0\Applications\ZAppSi\Dem o\SEDevice>make all
make -C makefiles/PC -f Makefile_PC_Gcc all APP_NAME=DemoSE
make[1]: Entering directory
'C:/BITCLOUD/BitCloud_PS_SAM3S_EK_1_10_0/BitCloud_PS_SAM3S_EK_1_10_0/Applications/ZAppSi/Demo/SEDevice/makefiles/PC'
A sintaxe do comando está incorrecta.
make[1]: *** [directories] Error 1
make[1]: Leaving directory
'C:/BITCLOUD/BitCloud_PS_SAM3S_EK_1_10_0/BitCloud_PS_SAM3S_EK_1_10_0/Applications/ZAppSi/Demo/SEDevice/makefiles/PC'
make: *** [all] Error 2
行
A sintaxe do comando está incorrecta.
翻译成英文意味着:“命令的语法不正确”
我已经尝试将项目更改为不同的目录,检查文件名中的空格,使用GNU make并使用MinGW make(mingw32-make),结果与“make”相同。我还检查了makefile中包含的所有文件,它们是对应的。
我不是makefile的专家,所以我请求帮助。 当make抛出这种类型的错误时,会出现什么主要问题?
答案 0 :(得分:0)
可能不会make
抛出此错误,但make执行的命令返回非零退出状态,在这种情况下状态为1(由于错误1);然后顶级make
因错误2而停止。请注意,make
默认情况下会在命令失败时立即停止。
由于输出没有显示执行了什么命令,因此无法确切地说明出了什么问题。
编辑:来自GNU make手册:
-d Print debugging information in addition to normal processing. The debugging information says which files are being considered for remaking, which file-times are being compared and with what results, which files actually need to be remade, which implicit rules are considered and which are applied---everything inter‐ esting about how make decides what to do. --debug[=FLAGS] Print debugging information in addition to normal processing. If the FLAGS are omitted, then the behavior is the same as if -d was specified. FLAGS may be a for all debugging output (same as using -d), b for basic debugging, v for more verbose basic debugging, i for showing implicit rules, j for details on invo‐ cation of commands, and m for debugging while remaking make‐ files.
我建议运行make --debug=j
来查看命令。