您好我在Eclipse中遇到麻烦,包括OpenCV库。我遵循很多教程,但我不能编译任何东西。这是控制台的输出。Eclipse + OpenCV + Cygwin - > cv.h:没有这样的文件或目录
Building file: ../hand.c
Invoking: Cygwin C Compiler
gcc -O2 -g -Wall -c -fmessage-length=0 -MMD -MP -MF"hand.d" -MT"hand.d" -o"hand.o" "../hand.c"
cygwin warning:
MS-DOS style path detected: D:\Eclipse_workspace_C++\HelloWorld\Default
Preferred POSIX equivalent is: /cygdrive/d/Eclipse_workspace_C++/HelloWorld/Default
CYGWIN environment variable option "nodosfilewarning" turns off this warning.
Consult the user's guide for more details about POSIX paths:
http://cygwin.com/cygwin-ug-net/using.html#using-pathnames
../hand.c:3:16: fatal error: cv.h: No such file or directory
compilation terminated.
subdir.mk:18: recipe for target `hand.o' failed
make: *** [hand.o] Error 1
我正在使用OpenCV2.0。
我在proyect属性中配置了C/C++构建 - >设置 - >工具设置选项卡 - >编译器和链接器来添加opencv库和标题,但我无法编译它。
我的eclipse项目的ScreenShoot。
做以下检查1)你有包括 “../include/opecv” 和” ../include/opencv2" 路径? 2)检查opencv和cygwin的环境变量是否设置正确。 – 2vision2 2013-05-13 07:00:19
嗨,环境变量设置。关于包含opencv2?我在opencv 2.0目录中没有这个文件夹。 – Patrick 2013-05-13 07:02:51
你不能使用opencv4 +版本吗?为什么坚持2.0? – 2vision2 2013-05-13 08:10:15