Deploying Standalone Executable with No MCR

조회 수: 32 (최근 30일)
Royi Avital
Royi Avital 2012년 5월 31일
이동: DGM 2023년 2월 22일
Hello. I have a simple M file which creates a GUI, let the user chose a text file, apply a simple manipulation on the text file and then save the result.
I want to create a standalone application from this file. I read the help on the subject which requires installation of the MCR on the target machine. The MCR by itself is more than a 300MB file.
Yet I saw appliactions, such as IMATEST http://www.imatest.com/, which uses MATLAB yet requires nothing from the target machine but the deployed executable.
How could that be done? How can I create a completely independent application?
Thank You.
  댓글 수: 1
Serge
Serge 2023년 2월 22일
이동: DGM 2023년 2월 22일
Well it's 2023 and the MCR is now a 3.7GB!
Plus it's now a zip with nearly 8k files, not a single file. (for windows)
This is a huge overhead for deplying MatLab code... (download > unzip > install > run)

댓글을 달려면 로그인하십시오.

채택된 답변

Kaustubha Govind
Kaustubha Govind 2012년 5월 31일
As you have already heard, the MCR is absolutely required to deploy executables generated using MATLAB Compiler. According to the imatest instructions, they have two types of MATLAB-related files:
  1. P-coded (ie. .m files encrypted with the .p extension) which can be invoked directly from MATLAB.
  2. DLL versions of MATLAB code which do need the MCR ("Imatest IT/DLL also comes with the Matlab Compiler Runtime Libraries. More information can be found at the MathWorks website or below.")
However, if you really do want to generate a standalone executable from your MATLAB code without the use of the MCR, please consider using MATLAB Coder. This product generates C/C++ code from MATLAB code, but only supports a limited subset of the MATLAB language for code generation.
  댓글 수: 3
Kaustubha Govind
Kaustubha Govind 2012년 6월 1일
Unfortunately, I don't think that is possible right now. I think the MCR is a monolith. Please feel free to confirm this with MathWorks Tech Support and also submit an enhancement request.
Walter Roberson
Walter Roberson 2012년 6월 1일
My understanding is that there is _some_ customization that can be done with MCR, but that the size difference is only about 30 Mb and the resulting MCR is only good for running the single program.

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 MATLAB Coder에 대해 자세히 알아보기

태그

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by