简体   繁体   English

OpenCV4Windows无法找到ostream.h,sstream.h和stdint.h

[英]OpenCV4Windows cant find ostream.h, sstream.h and stdint.h

I have been working with OpenCV4Android and produced a library to use in my android apps, i want to create the same library to use in any windows software, now using OpenCV4Windows . 我一直在使用OpenCV4Android,并制作了一个可在我的android应用程序中使用的库,现在我想使用OpenCV4Windows创建一个可在任何Windows软件中使用的

The problem is that I have been unable to compile the code due to different headers not found ( called by OpenCV) this is specially strange as i am still able to compile the same code for android (using OpenCV4Android) 问题是由于找不到不同的头而无法编译代码(由OpenCV调用),这特别奇怪,因为我仍然能够为android(使用OpenCV4Android)编译相同的代码

Already tried different versions of OpenCV4Windows and no success the following line: 已经尝试过不同版本的OpenCV4Windows,但以下行未成功:

g++ -c MMROI.cpp -ID:\software\OpenCV4Windows\opencv\build\include

gives this result: 给出以下结果:

"*In file included from D:\software\OpenCV4Windows\opencv\build\include\opencv2/core/cvdef.h:59,
                 from D:\software\OpenCV4Windows\opencv\build\include\opencv2/core.hpp:52,
                 from D:\software\OpenCV4Windows\opencv\build\include\opencv2/opencv.hpp:46,
                 from MMROI.hpp:4,
                 from MMROI.cpp:5:
D:\software\OpenCV4Windows\opencv\build\include\opencv2/hal/defs.h:274: stdint.h: No such file or directory
In file included from D:\software\OpenCV4Windows\opencv\build\include\opencv2/core.hpp:3107,
                 from D:\software\OpenCV4Windows\opencv\build\include\opencv2/opencv.hpp:46,
                 from MMROI.hpp:4,
                 from MMROI.cpp:5:
D:\software\OpenCV4Windows\opencv\build\include\opencv2/core/cvstd.inl.hpp:49: ostream: No such file or directory*"

我解决了这个问题,它是g ++的真正旧版本,通过重新安装cygwin并更新g ++和gcc软件包来解决

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM