Hello,
The -lcutil flag is for the linker, not the compiler, so it’s not in the inc/ directory but in the lib/ one (usually). As a rule of thumb, adding -lfoo to linker’s flags means that it should be linked with a file named libfoo.a (or libfoo.so). So just look for libcutil.a for instance.
Cédric
I do not have a version of libcutil.a on my pc hard disk. I found file that might work. Here is the latest output:
errol@fermi:~/NVIDIA_GPU_Computing_SDK/C/src/matrixMul$ nvcc -g -G -I…/…/common/inc -L…/…/lib -I /home/errol/NVIDIA_GPU_Computing_SDK/shared/inc -o matrixMul matrixMul.cu matrixMul_gold.cpp -lcutil
/usr/bin/ld: cannot find -lcutil
collect2: ld returned 1 exit status
errol@fermi:~/NVIDIA_GPU_Computing_SDK/C/src/matrixMul$ nvcc -g -G -I…/…/common/inc -L…/…/lib -I /home/errol/NVIDIA_GPU_Computing_SDK/shared/inc -L /home/errol/NVIDIA_GPU_Computing_SDK/C/lib -o matrixMul matrixMul.cu matrixMul_gold.cpp -lcutil
/usr/bin/ld: cannot find -lcutil
collect2: ld returned 1 exit status
errol@fermi:~/NVIDIA_GPU_Computing_SDK/C/src/matrixMul$ cd …
errol@fermi:~/NVIDIA_GPU_Computing_SDK/C/src$ cd …
errol@fermi:~/NVIDIA_GPU_Computing_SDK/C$ ls
bin common doc lib Makefile releaseNotesData Samples.html src tools
errol@fermi:~/NVIDIA_GPU_Computing_SDK/C$ cd lib
errol@fermi:~/NVIDIA_GPU_Computing_SDK/C/lib$ ls
libcutil_i386.a libparamgl_i386.a librendercheckgl_i386.a
errol@fermi:~/NVIDIA_GPU_Computing_SDK/C/lib$ pwd
/home/errol/NVIDIA_GPU_Computing_SDK/C/lib
errol@fermi:~/NVIDIA_GPU_Computing_SDK/C/lib$
As you can see the file is libcutil_i386.a. it is very similar to libcutil.a with an added i_386 at the end. It does not work as you can see above.
Adding the directory on the include list has no effect, it still cannot find -lcutil.
I did try copying libcutil_i386.a to -libcutil.a and got a different set of errors when I compiled. I am not showing those.
Someone on the forum simply renamed libcutil_i386.a to libcutil.a and they said it worked.
I am still not sure what is wrong. In the 3.0 32 bit CUDA where should the libcutil.a file be?
Newport_j