Why is MATLAB recognising an older runtime version and not the latest installed?

5 views (last 30 days)
I have installed MATLAB 2021a. But when I type "mcrinstaller" in the command window, the runtime is referenced to the 2020a version. I tried to change it, but still no change.
Kindly guide me with this.
Thank you!

Answers (1)

Rupesh
Rupesh on 21 May 2024
Edited: Rupesh on 21 May 2024
Hi Himanshu,
To resolve an issue where MATLAB references an older version of the MATLAB Compiler Runtime (MCR) despite having MATLAB 2021a installed, it's essential to verify the installed MCR versions, ensure the correct path is set, and use the "mcrinstaller" from the appropriate MATLAB version.
  • Verify Installed MCR Versions:
Check Installation Directories: Navigate to C:\Program Files\MATLAB\MATLAB Runtime on Windows
or the equivalent directory on macOS/Linux to see which MCR versions are installed.
  • Set the Correct Path:
Windows:
1] Access Environment Variables through Control Panel > System and Security > System >
Advanced system
2] Modify the PATH variable to point to the MATLAB 2021a directories instead of MATLAB 2020a.
macOS/Linux:
1] In the terminal, use echo $PATH to view the current path.
2] Edit your profile script (.bash_profile, .bashrc) to update the path to include the MATLAB 2021a .
directory.
  • Use the mcrinstaller from the Correct Version:
1] Navigate to the MATLAB 2021a installation directory in your system's file explorer or terminal.
2] Run the “mcrinstaller” executable directly from this directory to ensure you're using the version
associated with MATLAB 2021a.
You can refer to the below documentation to get a better understanding of MATLAB mcr installations.
Hope it helps!
Thanks

Categories

Find more on Introduction to Installation and Licensing in Help Center and File Exchange

Tags

Community Treasure Hunt

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

Start Hunting!