Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

/usr/bin/ld: cannot find -lcutil_x86_64

Tags:

cuda

I've installed latest nvidia sdk and toolkit. When I run any of th sdk examples I get the following error:

/usr/bin/ld: cannot find -lcutil_x86_64

Any help will be highly appreciated.

like image 635
SKhan Avatar asked Dec 25 '10 01:12

SKhan


2 Answers

In most of the CUDA frameworks installations I have been using, cutil was located in:

/sdk_installation_path/C/lib/libcutil_x86_64.a    

*(With /sdk_installation_path the path where you installed the CUDA sdk on your system. Frequently in /usr/local or /opt.)*

Moreover, I have always encountered cutil compiled as a static libary, understand you cannot dynamically link against it. However, you just need to add it on your compilation line, just the way you would do with any other object code generated from your source code:

nvcc foo.o /sdk_installation_path/C/lib/libcutil_x86_64.a -o foo
like image 80
jopasserat Avatar answered Oct 03 '22 06:10

jopasserat


Three different takes on finding more information

  1. run command locate cutil_x86_64
  2. run command find / -name '*cutil_x86_64*' -print
  3. search for cutil_x86_64 with google.

Option 1 is the fast way, and you can skip 2 if 1 finds anything.

The third option gives a post from NVIDIA forums discussing this problem as the first hit, combine the information you get from all of them.

like image 36
hlovdal Avatar answered Oct 03 '22 04:10

hlovdal