Why am I getting an error installing MATLAB on Ubuntu 24.04
313 views (last 30 days)
Show older comments
I have just tried to download MATLAB onto Ubuntu 24.04 and it is not working.
When I run ./install within matlab_R2024a_Linux, this is the output:
terminate called after throwing an instance of 'std::runtime_error'
what(): Failed to launch web window with error: Unable to launch the MATLABWindow application. The exit code was: 1
Aborted (core dumped)
When I then run ./bin/glnxa64/MATLABWindow , this is the output:
./bin/glnxa64/MATLABWindow: /home/eric1/Downloads/matlab_R2024a_Linux/bin/glnxa64/libstdc++.so.6: version `GLIBCXX_3.4.29' not found (required by /lib/x86_64-linux-gnu/libgallium-24.2.1 - kisak-mesa PPA.so)
./bin/glnxa64/MATLABWindow: /home/eric1/Downloads/matlab_R2024a_Linux/bin/glnxa64/libstdc++.so.6: version `GLIBCXX_3.4.29' not found (required by /lib/x86_64-linux-gnu/libLLVM-17.so.1)
./bin/glnxa64/MATLABWindow: /home/eric1/Downloads/matlab_R2024a_Linux/bin/glnxa64/libstdc++.so.6: version `CXXABI_1.3.13' not found (required by /lib/x86_64-linux-gnu/libLLVM-17.so.1)
./bin/glnxa64/MATLABWindow: /home/eric1/Downloads/matlab_R2024a_Linux/bin/glnxa64/libstdc++.so.6: version `GLIBCXX_3.4.30' not found (required by /lib/x86_64-linux-gnu/libLLVM-17.so.1)
./bin/glnxa64/MATLABWindow: /home/eric1/Downloads/matlab_R2024a_Linux/bin/glnxa64/libstdc++.so.6: version `GLIBCXX_3.4.30' not found (required by /lib/x86_64-linux-gnu/libicuuc.so.74)
I have tried reading through these guides:
I have tried other solutions on Stack Over flow and nothing has worked.
Answers (2)
Shubham
on 8 Sep 2024
Hey William,
It appears that the libstdc++ library is missing the required GLIBCXX versions needed by MATLAB. You can use the MATLAB's libraries by either modifying the environment variables or by updating the libstdc++ libraries.
For more information on the issue, please refer to this MATLAB Answers thread by MathWorks: https://www.mathworks.com/matlabcentral/answers/643300-why-do-i-receive-the-error-libstdc-so-6-version-glibcxx_3-4-22-not-found-when-trying-to-star
I hope this helps!
1 Comment
Rob Campbell
on 1 Nov 2024 at 16:04
The instructions you link to are for Ubunu 18.04 but we are having issues with 24.04. Further, we are having trouble with the install and the instructions are for issues where MATLAB has already been installed. I still can not install MATLAB on Ubuntu 24.04
YU-KUAN
on 11 Sep 2024
Tried like 10 different ways but nothing works for 2024a (same on ubuntu 24.04)
Therefore I downloaded an earlier version (in my case i randomly chose 2021b) and follow the steps:
1. Re-do the install: failed the same way
2. Made sure all GLIBCXX version not found by running ./bin/glnxa64/MATLABWindow can be found using:
strings /usr/lib/x86_64-linux-gnu/libstdc++.so.6 | grep GLIBC
(If not, you may want to sudo apt install libstdc++6)
3. remove all ./bin/glnxa64/libstdc++* ./sys/os/glnxa64/libstdc++* ./sys/os/glnxa64/libgcc*
mkdir ./bin/glnxa64/exclude
mkdir ./sys/os/glnxa64/exclude
mv ./bin/glnxa64/libstdc++* ./bin/glnxa64/exclude
mv ./sys/os/glnxa64/libstdc++* ./sys/os/glnxa64/exclude
mv ./sys/os/glnxa64/libgcc ./sys/os/glnxa64/exclude
4. finally, redo the install
sudo -H ./install
1 Comment
Rob Campbell
on 4 Nov 2024 at 11:59
Edited: Rob Campbell
on 4 Nov 2024 at 12:37
After doing this with R2021b and Ubuntu 24.04 I still get the error:
$ ./bin/glnxa64/MATLABWindow
./bin/glnxa64/MATLABWindow: symbol lookup error: /lib/x86_64-linux-gnu/libharfbuzz.so.0: undefined symbol: FT_Get_Color_Glyph_Layer
A spot of Googling indicated this error is related to an older free type face library. So I also removed bin/glnxa64/libfreetype.so.6.16.0 The installer started after this. R2024a did not need the fonts removed and the installer started after the files you list were removed.
See Also
Categories
Find more on Introduction to Installation and Licensing in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!