OpenCV 以前使用支持 CUDA 的卡在我的机器上正确安装。安装 Cuda 5 工具包后,OpenCV 无法从源代码构建并出现以下错误,../../lib/libopencv_core.so.2.4.1: error: undefined reference to 'cuDeviceGetAttribute'。我有点卡在这里,不知道该怎么办。当谈到从源头构建东西时,我是一个菜鸟。该工具包很好,我能够编译 Cuda 代码。有想法该怎么解决这个吗?解决方案的方向也很棒!
编辑 - 制作输出
[ 4%] Built target opencv_core
[ 5%] Built target opencv_ts
[ 12%] Built target opencv_imgproc
[ 15%] Built target opencv_highgui
Linking CXX executable ../../bin/opencv_perf_core
../../lib/libopencv_core.so.2.4.1: error: undefined reference to 'cuDeviceGetAttribute'
collect2: ld returned 1 exit status
make[2]: *** [bin/opencv_perf_core] Error 1
make[1]: *** [modules/core/CMakeFiles/opencv_perf_core.dir/all] Error 2
make: *** [all] Error 2