2013-03-07 129 views
0

當我嘗試運行「讓所有」與一些複雜makefile文件我得到這個錯誤:使錯誤:「使[1]:*** [目錄]錯誤1」

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製作,還可以使用MinGW的make(mingw32-make)a結果與「make」相同。我還檢查了包含在makefile中的所有文件,並且它們對應。

我不是makefile的專家,所以我在尋求幫助。 當引發這種類型的錯誤時會發生什麼主要問題?

回答

0

引發此錯誤的可能不是make,而是由make執行的命令以非零退出狀態返回,在本例中爲狀態1(由於錯誤1);那麼頂級make會停止並顯示錯誤2.請注意,默認情況下,make會在命令失敗時立即停止。 由於輸出沒有顯示執行了什麼命令,因此無法準確判斷出了什麼問題。

編輯:從GNU使手動:

-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看到的命令。

+0

如何正確「調試」我的生成文件,以查看是否有什麼特效?任何提示? – eduardo 2013-03-07 16:10:15

+0

我已經編輯了關於調試的信息。 – Jens 2013-03-08 09:25:52