Matlab Compiler error: mclmcr initialization failed

35 vues (au cours des 30 derniers jours)
Eduardo Sousa
Eduardo Sousa le 21 Juil 2020
Commenté : 海伟 le 2 Jan 2025
After compiling a appdesigner window to a desktop app I can't install it and run it.
I allways get an error window with the text "mclmcr initialization failed"
I tried compiling the app from the appdesigner tool and from the Application Compiler app both with "runtime downloaded from web option and with runtime included in package option active and the results were the same in all situations.
Do you have any thoughts about how to fix this issue?
The app uses the following licences:
distrib_computing_toolbox
image_toolbox
neural_network_toolbox
  1 commentaire
Eduardo Sousa
Eduardo Sousa le 21 Juil 2020
Just to add some extra info on the previous issue: I tried with one of the mathworks default apps (Mortgage.mlapp) and the result was the same, it compiled, and let me intal the app but when I tried to run it an error window showed up with the text "mclmcr initialization failed" so the problem does not depend on the actual code, but somewhere else.

Connectez-vous pour commenter.

Réponses (1)

Kautuk Raj
Kautuk Raj le 2 Jan 2025
I realized that some DLL libraries are being loaded from the 'System32' folder instead of the <MCRroot> directory.
I tried moving the "MATLABWebAppServer.exe" from where it is currently to the following location and it worked for me:
C:\Program Files\MATLAB\MATLAB Runtime\v97\bin\win64
Then, launch the application from that location to try and force it to use the correct DLL files. Before launching, it would also be worth trying to delete your MCRCacheroot folder. The directory for this folder can be found below:
C:\Users\<username>\AppData\Local\Temp\<username>\mcrCache9.7\
I hope these steps will guide you towards solving the issue.
  1 commentaire
海伟
海伟 le 2 Jan 2025
Thank you for your idea, it has been enlightening! I've found that you can simply copy the 'v97\bin\win64\mclmcr.dll' file into the same directory as the '.exe' application, and the application will run!

Connectez-vous pour commenter.

Catégories

En savoir plus sur Introduction to Installation and Licensing dans Help Center et File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by