ingowald / optix7course

Apache License 2.0
452 stars 80 forks source link

No rule to make target '/usr/local/cuda/lib64/libcuda.so' #19

Closed yuhao closed 3 years ago

yuhao commented 3 years ago

Trying to build the code. After "make" I got:

[  1%] Building CXX object common/gdt/CMakeFiles/gdt.dir/gdt/gdt.cpp.o
[  2%] Linking CXX static library ../../libgdt.a
[  2%] Built target gdt
[  3%] Building CXX object example01_helloOptix/CMakeFiles/ex01_helloOptix.dir/main.cpp.o
make[2]: *** No rule to make target '/usr/local/cuda/lib64/libcuda.so', needed by 'ex01_helloOptix'.  Stop.
CMakeFiles/Makefile2:185: recipe for target 'example01_helloOptix/CMakeFiles/ex01_helloOptix.dir/all' failed
make[1]: *** [example01_helloOptix/CMakeFiles/ex01_helloOptix.dir/all] Error 2
Makefile:83: recipe for target 'all' failed
make: *** [all] Error 2

A make verbose dump shows that issue is at:

make -f example01_helloOptix/CMakeFiles/ex01_helloOptix.dir/build.make example01_helloOptix/CMakeFiles/ex01_helloOptix.dir/build

where example01_helloOptix/CMakeFiles/ex01_helloOptix.dir/build doesn't exist.

Any suggestions? Thanks.

ingowald commented 3 years ago

This looks like something is wrong with your cuda installation. Does that libcuda.so exist and is readable by that user? Cmake did find it, apparently, but seems linker can't use it for some reason.

yuhao commented 3 years ago

Hmm seems like so. Thanks.