1

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.

  • /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)

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

Thanks.

1
  • Your install location, /usr/lib/cuda is odd, but there is no libdevice.so, that is a shorthand for all the specific cuda libraries, see the man page, man libdevice.
    – ubfan1
    Jun 29 '20 at 17:34
0

I am not sure whether this will help but I will share my configurations here. I configured environment variables as follows.

export PATH="/usr/local/cuda-11.0/nsight-compute-2020.1.0:$PATH"
export PATH="/usr/local/cuda-11.0/bin:$PATH"
export CUDA_HOME="/usr/local/cuda-11.0"
export LD_LIBRARY_PATH="/usr/local/cuda-11.0/lib64":$LD_LIBRARY_PATH

Before adding CUDA_HOME and LD_LIBRARY_PATH, I got the same error "nvcc fatal : Path to libdevice library not specified".


when I'm doing nvcc --version, I'm seeing version 9.1. which is also weird

Is your /usr/lib/cuda/bin the first item in $PATH? Bash finds the first program it matches. Maybe /usr/local/cuda/bin is before your /usr/lib/cuda/bin?

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)

In my case, libdevice is located at /usr/local/cuda-11.0/nvvm/libdevice rather than /usr/local/cuda-11.0/libdevice.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.