module unsafe for SAFESEH image C++(模块对于 SAFESEH 图像 C++ 不安全)
问题描述
我使用的是 Microsoft Visual Studio 2011 Professional Beta
I am using Microsoft Visual Studio 2011 Professional Beta
我正在尝试运行 OpenCV C++ 文件(http://opencv.willowgarage.com/wiki/欢迎),我使用 cMake & 编译Visual Studio 编译器.
I am trying to run the OpenCV C++ files (http://opencv.willowgarage.com/wiki/Welcome) that I have compiled using cMake & the Visual Studio Complier.
然而,当我去调试项目时,我收到了 600 多个错误,其中大部分是:
However when I go to debug the project I get 600+ errors most of them being:
错误 LNK2026:模块对于 SAFESEH 图像不安全.
error LNK2026: module unsafe for SAFESEH image.
显然这些文件在 opencv_ffmpeg 项目中,但我找不到它们,我查看了 Microsoft 帮助页面上的 safeseh Safe Exception Handlers 页面,但找不到任何明确的答案.
Apparently these files are in the opencv_ffmpeg project but I couldn't find them, I have had a look at the safeseh Safe Exception Handlers page on the Microsoft help page but I couldn't find any definitive answers.
我想知道是否有其他人遇到过这个问题,他们是否设法解决了这个问题.
I was wondering if anyone else has had this problem and if they managed to fix it.
推荐答案
来自评论:
当您链接包含由早期版本的编译器创建的代码的 .obj 或 .lib 时,会发生这种情况.如果您下载了 opencv_ffmpeg 的二进制文件而不是源文件,这当然很常见.您可以关闭链接器选项,但是您仍然会遇到可以字节的 CRT 版本不兼容性.从源代码重建库.– 汉斯·帕桑特 5 月 15 日 13:01
感谢您的帮助,它奏效了 – 亚伦·汤普森 5 月 17 日 14:50
This happens when you link an .obj or .lib that contains code created by an earlier version of the compiler. Which of course would be common if you downloaded a binary for opencv_ffmpeg instead of the source. You can turn the linker option off but then you'll still have a CRT version incompatibility that can byte. Rebuild the library from source. – Hans Passant May 15 at 13:01
Thanks for the help, it worked – Aaron Thompson May 17 at 14:50
这篇关于模块对于 SAFESEH 图像 C++ 不安全的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!
本文标题为:模块对于 SAFESEH 图像 C++ 不安全


- 静态初始化顺序失败 2022-01-01
- C++ 协变模板 2021-01-01
- Stroustrup 的 Simple_window.h 2022-01-01
- 一起使用 MPI 和 OpenCV 时出现分段错误 2022-01-01
- 与 int by int 相比,为什么执行 float by float 矩阵乘法更快? 2021-01-01
- 如何对自定义类的向量使用std::find()? 2022-11-07
- 近似搜索的工作原理 2021-01-01
- 使用/clr 时出现 LNK2022 错误 2022-01-01
- STL 中有 dereference_iterator 吗? 2022-01-01
- 从python回调到c++的选项 2022-11-16