I just tried installing CUDA 7.5 on my laptop. I disabled lightdm
and did sudo sh cuda7.5.run
. The driver installation passed but then I got an error Unsupported compiler ...
and the installation fails. How can I resolve this issue?
I had a similar issue installing CUDA 7.5 in Ubuntu 16.04.
I've solved it using gcc/g++ 4.8 instead of 5.2.
You can install it and switch the default version using the command update-alternatives --install
For gcc 4.8 do:
sudo apt-get install gcc-4.8
sudo update-alternatives --remove-all gcc
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-4.8 10
For g++ 4.8 do:
sudo apt-get install g++-4.8
sudo update-alternatives --remove-all g++
sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-4.8 10
The problem was with Ubuntu 15.10
. I installed 14.04
and could install CUDA. However, for my laptop there was a subtle point to mention. I had to install the NVIDIA driver via System Settings --> Software & Updates --> Additional Drivers
and selecting the tested
driver. Then I installed CUDA and answered No
to driver installation bundled with CUDA installation file.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With