Re: [問題] 請問MEX-file已回收

看板MATLAB作者 (恩)時間15年前 (2010/07/30 03:34), 編輯推噓2(205)
留言7則, 3人參與, 最新討論串3/3 (看更多)
遇到的問題: (題意請描述清楚) 問題一: 想用visual c++ release 功能 編譯matlab的mex檔案 問題二: 之前有朋友用這個方法編譯出來的.dll檔 該.dll檔卻無法用visual c++打開 請問要怎麼解決呢? 還是可以使用其他軟體打開呢? 感恩。 希望得到的正確結果: 希望可以知道怎麼編譯出.dll檔案 以及可以知道.dll檔案裡頭的程式 感恩。 如果不恰當請告知,我會自D。謝謝。 ※ 引述《huiocean (恩)》之銘言: : 各位強者大家好 : 小妹用輸入mex-setup : 卻跑出這樣的結果 : Select a compiler: : [1] Lcc-win32 C 2.4.1 in C:\PROGRA~1\MATLAB\R2008b\sys\lcc : [0] None : Compiler: 1 : Trying to update options file: : C:\Users\Cindy\AppData\Roaming\MathWorks\MATLAB\R2008b\mexopts.bat : From template: : C:\PROGRA~1\MATLAB\R2008b\bin\win32\mexopts\lccopts.bat : Done . . . : ************************************************************************** : Warning: The MATLAB C and Fortran API has changed to support MATLAB : variables with more than 2^32-1 elements. In the near future : you will be required to update your code to utilize the new : API. You can find more information about this at: : http://www.mathworks.com/support/solutions/data/1-5C27B9.html?solution=1-5C27B9 : Building with the -largeArrayDims option enables the new API. : ************************************************************************** : Usage: : MEX [option1 ... optionN] sourcefile1 [... sourcefileN] : [objectfile1 ... objectfileN] [libraryfile1 ... libraryfileN] : or (to build an Ada S-function): : MEX [-v] [-g] -ada <sfcn>.ads : Use the -help option for more information, or consult the MATLAB API : Guide. : C:\PROGRA~1\MATLAB\R2008B\BIN\MEX.PL: Error: No file names given. : ??? Undefined function or variable 'setup'. : 請問要怎麼解決呢? : 謝謝各位 : ※ 引述《huiocean (恩)》之銘言: : : 請問一下, : : 我上網抓了一個wii mote的程式 : : 他的檔案形式是M-file : : 其中他會呼叫一個函數(另一個檔案) : : 而那個被呼叫的函數(該檔案)的檔案形式是MEX-file : : 這樣code跑出來會有error@@! : : 請問該怎麼辦呢,應該要多安裝什麼軟體嗎? : : 謝謝各位的解答,感激不盡QQ -- ※ 發信站: 批踢踢實業坊(ptt.cc) ◆ From: 140.113.182.197 ※ 編輯: huiocean 來自: 140.113.182.197 (07/30 03:36)

07/30 09:09, , 1F
...等等 你的目標是使用matlab code吧 為什麼需要DLL?
07/30 09:09, 1F

07/30 09:11, , 2F
compile MEX雖然可以用VisualC++ 但是是直接在matlab裡
07/30 09:11, 2F

07/30 09:12, , 3F
用mex這個指令喔 不需要另外開visualC
07/30 09:12, 3F

07/30 09:14, , 4F
MEXfile的主程式應該個mexFunction() 一開始的目的就是做為
07/30 09:14, 4F

07/30 09:15, , 5F
與matlab溝通的接口 而VisualC並沒辦法知道這件事情
07/30 09:15, 5F
請問要怎麼直接在matlab 使用mex,而不用開visual C呢 mexFunction()用可以呼叫他嗎,謝謝 ※ 編輯: huiocean 來自: 140.113.182.197 (07/30 10:53)

07/30 12:18, , 6F
就直接用matlab的editor寫就好了
07/30 12:18, 6F

07/30 20:28, , 7F
看可不可以拿到matlab原始檔 不然有dll也沒用
07/30 20:28, 7F
※ 編輯: huiocean 來自: 140.113.182.197 (08/05 21:20)
文章代碼(AID): #1CKTV8FB (MATLAB)
文章代碼(AID): #1CKTV8FB (MATLAB)