How to run a standalone executable compiled in older version FROM console
8 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
Pim Hacking
le 24 Jan 2020
Réponse apportée : Andrew Janke
le 31 Jan 2020
I have a standalone executable that was compiled in MCR 9.1 (I do not have the original files)
I need to run that standalone executable from a script in matlab R2018b (MCR 9.5).
I have installed MCR 9.1.
Running the executable on its own works fine. However, when I try to run it from Matlab it complains about not being able to find MCR 9.1
I also tried calling a bat file from Matlab, but it still complains (running the bat file by itself works like a charm).
Any tips?
0 commentaires
Réponse acceptée
Andrew Janke
le 31 Jan 2020
Check the state of the %PATH% environment variable from within Matlab. Matlab adds its own libs to the PATH, and those libs overlap what is in the MCR, so when you're running a compiled-Matlab command via system() from within Matlab 9.5, you're running it against MCR 9.5, even if you have MCR 9.1 installed separately on your computer. You will probably have to make a little batch file that re-adds the MCR 9.1 lib paths to the front of your %PATH% variable, and call your standalone app through that bat file.
0 commentaires
Plus de réponses (0)
Voir également
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!