我正嘗試在Matlab中使用Deploytool爲我的項目生成一個.exe文件來創建Windows獨立應用程序。 (如此處所述:http://www.mathworks.co.uk/products/demos/compiler/deploytool/index.html)。Matlab部署工具 - Windows獨立應用程序
問題是,當在Deploytool中添加我的文件,然後按Build按鈕它要求我使用mbuild -setup設置我的編譯器。當我這樣做的唯一選擇我得到的是:
Would you like mbuild to locate installed compilers [y]/n? n
Select a compiler:
[1] Microsoft Visual C++ 2005 SP1
[2] Microsoft Visual C++ 2008 Express
[3] Microsoft Visual C++ 2008 SP1
[0] None
,當我選擇的任何我得到這些:
*The default location for Microsoft Visual C++ 2008 Express compilers is C:\Program Files (x86)\Microsoft Visual Studio 9.0,
but that directory does not exist on this machine.
Please enter the location of your compiler:*
我也得到了以下錯誤,當我建:
*Could not find the compiler "cl" on the DOS path.
Use mbuild -setup to configure your environment properly.
C:\PROGRA~1\MATLAB\R2010A\BIN\MEX.PL: Error: Unable to locate compiler.
Error: An error occurred while shelling out to mbuild (error code = 2).
Unable to build executable.*
你能幫我解決這個問題嗎?
在此先感謝。
哪個編譯器,你已經安裝在你的機器上?如果讓「mbuild -setup」找到已安裝的編譯器,會發生什麼? – Edric
沒有選項時,我讓它成立自己。我應該如何安裝編譯器?我需要讓他們專門爲MATLAB? – Reyhaneh
你需要安裝一個編譯器,我相信在Visual Studio Express編譯器可以從微軟免費獲得。 – Edric