opencv 2413测试, /usr/bin/ld: 找不到 -lopencv_dep_cudart

问题和解决方案如下:

jennifer@jennifer-pc:~/DisplayImage$make

[ 50%] Linking CXX executable DisplayImage
/usr/bin/ld: 找不到 -lopencv_dep_cudart
collect2: error: ld returned 1 exit status
CMakeFiles/DisplayImage.dir/build.make:120: recipe for target 'DisplayImage' failed
make[2]: *** [DisplayImage] Error 1
CMakeFiles/Makefile2:67: recipe for target 'CMakeFiles/DisplayImage.dir/all' failed
make[1]: *** [CMakeFiles/DisplayImage.dir/all] Error 2
Makefile:83: recipe for target 'all' failed
make: *** [all] Error 2

jennifer@jennifer-pc:~/DisplayImage$cmake -DCUDA_USE_STATIC_CUDA_RUNTIME=OFF
-- Configuring done
-- Generating done
-- Build files have been written to: /home/jennifer/DisplayImage
jennifer@jennifer-pc:~/DisplayImage$make
[ 50%] Linking CXX executable DisplayImage
[100%] Built target DisplayImage
jennifer@jennifer-pc:~/DisplayImage$./DisplayImage lena.jpeg
init done

opengl support available

opencv 2413测试, /usr/bin/ld: 找不到 -lopencv_dep_cudart_第1张图片

你可能感兴趣的:(opencv,opencv,测试,ubuntu)