make 不能處理目錄名或檔名中有空格的情況

2021-09-02 23:54:39 字數 394 閱讀 9896

gnu make can't handle spaces in pathnames

cygwin中的make.exe 不能處理檔名中包含有空格的情況。網路上有人指出這個bug。但為了版本相容。官方似乎不準備改正。

使用 mcp2make 1.0.2 將ads的工程檔案轉換成makefile檔案時,其中有空格的路徑名被雙引號包括起來了。

"c:\program files\arm\adsv1_2\include\math.h"

"c:\program files\arm\adsv1_2\include\string.h"

解決的方法是:

廢棄make.exe,改用微軟的nmake.exe(vs2015自帶的)

含有空格的路徑名,用雙引號包括起來,就可以正確處理了。

Go 路徑 目錄名 包名 檔名

1 目錄結構 bin pkgsrc pk1pk2 function1.go function2.go index.go 2 function1.go 檔案內容 package pk3 func function test3 3 function2.go 檔案內容 package pk3 func f...

shell提取檔名和目錄名

用於字串的讀取,提取和替換功能,可以使用 提取字串1.提取檔名 root localhost test var mnt aaa test test.txt root localhost test echo test.txt2.提取字尾 root localhost test echo txt3.提取...

shell 提取檔名和目錄名

在寫shell指令碼中,經常會有需要對路徑和檔名做處理。有時候犯不著用sed命令來操作。bash提供的變數操作和一些外部命令都能很好的處理。var dir1 dir2 file.txt echo file.txt 在shell指令碼中,可以使用變數來儲存這個結果,再加以利用,如file 我們將 換成...