Open MahmoudAbdelrehim opened 4 years ago
specifying the cuda libs during configure solved it for me: ../configure LIBS="-lcuda -lcudart"
Not sure what caused it though. For me it worked well with cuda 10.0 on a NVIDIA Jetson TX2 and after I wiped it and flashed it with a newer cuda version 10.2 I got the linker errors.
It seems like for some reason config/find_cuda_libs.sh
is not able to extract the libraries anymore.
Edit: you also need to set LDFLAGS: ../configure LIBS="-lcuda -lcudart" LDFLAGS="-L/usr/local/cuda/lib64"
add ' -lcuda -lcudart' to common.mk.in
……
LIBS = @LIBS@ -lcudart -lcuda
……
btw, compile SHOC in nvidia , and occurred error message " nvcc fatal : unsupported gpu architechture 'compute_30'"
you can disable gencode=arch=xxx
with `CUDA_CPPFLAGS='-I/usr/local/cucda/include" to fix it.
I have got an error while trying to build the shoc directory the problem is while compiling for BusSpeedDownload, hence my cuda path is set. one of the errors I have got is: /common/main.cpp:60: undefined reference to `cudaSetDevice' ... Makefile:329: recipe for target 'BusSpeedDownload' failed make[4]: *** [BusSpeedDownload] Error 1