- (If you don't already have the ZIP-file for the RE installer) Execute "compiler.runtime.download" in the MATLAB Command Window.
- After the download completes, MATLAB will print out the path where it was installed. For example: C:\Users\<username>\AppData\Local\Temp\<username>\MCRInstaller24.1\MATLAB_Runtime_R2024a_win64.zip
- Move the file to a permanent directory that MATLAB will be able to access. For example: C:\Program Files\MATLAB\MATLAB Runtime\MATLAB_Runtime_R2024a_win64.zip
- In MATLAB, click the "Preferences" button in the "Environment" section of the "HOME" toolstrip.
- Select the "MATLAB Compiler" preferences, and then enter the path from Step 3 in the text field.
How can I package the MATLAB Runtime Installer with my standalone application from a specific directory?
13 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
MathWorks Support Team
el 26 de Jul. de 2024
Editada: MathWorks Support Team
el 26 de Jul. de 2024
I am using the Application Compiler to build standalone desktop applications from my MATLAB code with MATLAB Compiler. I am using the "Runtime included in package" option to package the MATLAB Runtime with my application installer.
I am using "compiler.runtime.download" to download the ZIP-file for the MATLAB Runtime installer. However, the file is downloaded to a temporary directory. For example, the MATLAB Runtime for R2024a on Windows is downloaded to:
C:\Users\<username>\AppData\Local\Temp\<username>\MCRInstaller24.1\MATLAB_Runtime_R2024a_Update_4_win64.zip
After a few days, the temporary directory is cleared by my operating system, and I need to redownload it in order to package the Runtime with my application installer. How can I configure MATLAB to store the Runtime installer in a non-temporary directory to package with my standalone applications?
Respuesta aceptada
MathWorks Support Team
el 26 de Jul. de 2024
Editada: MathWorks Support Team
el 26 de Jul. de 2024
Executing "compiler.runtime.download" will always download the Runtime installer ZIP-file to a temporary directory. After downloading, the file can be moved to a different location, and you can update the MATLAB preferences to point to the new location.
Use the following procedure to store the Runtime installer in a custom directory and configure MATLAB to use that location for the "Runtime included in package" option:
Now, selecting the "Runtime included in package" option in the Application Compiler will use the Runtime installer located at the path entered in Step 5.
0 comentarios
Más respuestas (0)
Ver también
Categorías
Más información sobre Introduction to Installation and Licensing en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!