Nvcc fatal : Path to libdevice library not specified

As mentioned above I’m receiving :

nvcc fatal   : Path to libdevice library not specified

After searching on the web , I’m sure that this is path issues, but mine is a bit different, and I wasn’t able to solve it.

  • Somehow my CUDA is not installed in /usr/local, but in /usr/lib/cuda

  • My nvcc path is at : /usr/bin/nvcc

  • When I’m trying to install :

     conda install cudatoolkit=10.0

    I’m getting a notice that it is already installed , but when I’m doing nvcc --version, I’m seeing
    version 9.1. which is also weird.
    – All the previous time I installed cudatoolkit=10.0, I got cuda10-0 inside /usr/local, now nothing.

  • /usr/lib/cuda/bin is in $PATH, and LD_LIBRARY_PATH=/usr/lib/cuda/lib64

  • I also find out that I have nvidia-cuda-toolkit at /usr/lib/nvidia-cuda-toolkit, and that libdevice is inside, (i.e /usr/lib/nvidia-cuda-toolkit/libdevice), also bin, but there is no lib64 inside

I’m really clueless, and I’ll be happy for your help.