Possible to export standalone MATLAB executable WITH toolboxes?
조회 수: 25(최근 30일)
표시 이전 댓글
Bo 2014년 6월 12일
답변: Prasad Kalane 2014년 7월 4일
I have a program that requires the use of several toolboxes, two of which are not actually provided by MATLAB. I understand that the Matlab Compiler only supports a very limited subset of normal functions when exporting standalone applications. However, is it possible at all to either compile the programs with the toolboxes, or even create the executable and send it to somebody along with the required toolboxes so he/she can run it without Matlab?
Honglei Chen 2014년 6월 12일
MATLAB Compiler supports many toolboxes, you can find out the list here
Image Analyst 2014년 6월 12일
That is not true. In fact I believe the opposite is what is true: MATLAB supports nearly all functions when built into a standalone executable. The tools it does not build in are things like standalone utilities with their own extensive user interface, like imtool() for instance. Those are a minority. I've compiled dozens of apps and have never had a problem with not getting what I need or want.
Whoever told you "Matlab Compiler only supports a very limited subset of normal functions" is mistaken.
Adam Filion 2014년 6월 12일
편집: Adam Filion 2014년 6월 12일
As noted in other answers, almost everything you do with MATLAB can be compiled with MATLAB Compiler. It's possible whoever told you this confused MATLAB Compiler with MATLAB Coder, which actually translates MATLAB into standalone C code and does indeed have a more limited set of supported functions. For the list of what you can and can't compile with MATLAB Compiler, see here:
For the rest of your question on including toolboxes not created by MathWorks, the MATLAB Compiler automatically does a dependency check and grabs everything it thinks the application needs, including user created files and custom toolboxes. If it somehow misses something, you can also manually add files or entire directories, so using non-MathWorks toolboxes with MATLAB Compiler should be no problem from a technical standpoint. However you should check any licensing for the non-MathWorks toolboxes to make sure you are in compliance when distributing your application.
Prasad Kalane 2014년 7월 4일
IF your code is running well in to MATLAB & it does not contain any of the listed function, apps(available at http://www.mathworks.in/products/compiler/supported/compiler_support.html ),Then you can successfully create standalone application. I have compile several Video processing apps without addition of any Toolbox, as MATLAB grab necessary files(as stated by Adam Filion ).
You can add MCR alongwith that application
Find more on C Shared Library Integration in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!Start Hunting!