当我尝试在 Ubuntu 上将 cmake 转换为 OpenCv-2.4.3 时,出现此错误:
CMake Error: The following variables are used in this project, but they are set to NOTFOUND. Please set them or make sure they are set and tested correctly in the CMake files: CUDA_nvcuvid_LIBRARY (ADVANCED)
然后,我在 CMakeLists.txt 中禁用了“with_cuda”选项。之后,我收到了这个警告:
The source directory is the same as binary directory. "make clean" may damage the source tree
我的构建文件夹中没有“makefile”,所以我无法安装 OpenCV-2.4.3。
最佳答案
我刚刚解决了这个问题。 操作系统:Linux Mint 13/64 位,CUDA 5.0。它也应该适用于 Ubuntu。
问题是您需要从 /usr/lib 创建一个指向位于
。/usr/lib/nvidia-current/
中的 libnvcuvid.so
的链接/
请在终端中执行:
su -c 'ln -s /usr/lib/nvidia-current/libnvcuvid.so /usr/lib/libnvcuvid.so && ln -s /usr/lib/nvidia-current/libnvcuvid.so.1 /usr/lib/libnvcuvid.so.1'
生成的构建文件没有错误。我还要补充一点,您不应该对 OpenCV 使用 apt-get,因为存储库包含该库的旧版本。
关于ubuntu - 在 Ubuntu 上安装 OpenCV-2.4.3 时出错,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/13191874/