Today I updated my NVIDIA driver from 440xx to 450xx. As a consequence, I had to re-install CUDA and cudnn.
(I should also add that while reinstalling CUDA and cudnn I also updated them from 10.2 to 11 and 7 to 8 respectively)
I needed to add
export PATH=/opt/cuda/bin:$PATH to my bashrc to be able to use
nvcc - which is weird since
nvcc worked before I updated my drivers and reinstalled CUDA and cudnn. (What might be happening here?)
But this created an issue - the gcc inside /opt/cuda/bin is gcc 9, whereas the system gcc is 10. I do not want to use gcc 9, I want to use gcc 10.
Before I updated my NVIDIA driver today and had to point bashrc to /opt/cuda/bin I was able to use both nvcc and gcc 10.
For completion’s sake, I checked which GCC versions are installed on my system -
[reik@reik-msi ~]$ pacman -Q | grep gcc avr-gcc 10.2.0-1 gcc 10.2.0-1 gcc-fortran 10.2.0-1 gcc-libs 10.2.0-1 gcc7 7.5.0-2 gcc7-libs 7.5.0-2 gcc8 8.4.0-1 gcc8-libs 8.4.0-1 gcc9 9.3.0-3 gcc9-libs 9.3.0-3 lib32-gcc-libs 10.2.0-1