Error C1047: Object file created with an older compiler than other objects(错误 C1047:使用比其他对象更旧的编译器创建的对象文件)
问题描述
我有一个项目,我正在 Windows 7 上的 Visual Studio 2008 SP1 中以 C++ 发布模式构建,当我构建它时,我不断收到:
I have a project that I'm building in C++ in Release mode in Visual Studio 2008 SP1 on Windows 7 and when I build it I keep getting:
致命错误 C1047:对象或库文件'.Releasefoobar.obj'是用较旧的编译器创建的比其他物体;重建旧的对象和库.
fatal error C1047: The object or library file '.Releasefoobar.obj' was created with an older compiler than other objects; rebuild old objects and libraries.
链接时发生错误.
我尝试删除特定的目标文件并重新构建,但这并不能解决问题.我也试过吹掉整个发布构建文件夹并重建,但这也没有解决它.有什么想法吗?
I've tried deleting the specific object file and rebuilding but that doesn't fix it. I've also tried blowing away the whole release build folder and rebuilding but that also didn't fix it. Any ideas?
推荐答案
我建议重新安装 VS 2008 SP1.在此期间您是否安装了不同的 VS(例如 VS Express)?已知这会干扰现有的 VS 安装.
I would suggest reinstalling VS 2008 SP1. Have you installed a different VS (e.g. VS Express) in the meantime? This is known to cause interference with an existing VS installation.
您可以尝试通过从 Visual Studio 命令提示符运行 cl.exe
和 link.exe
来检查编译器和链接器版本.
You could try checking the compiler and linker versions by running cl.exe
and link.exe
from the Visual Studio command prompt.
这篇关于错误 C1047:使用比其他对象更旧的编译器创建的对象文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!
本文标题为:错误 C1047:使用比其他对象更旧的编译器创建的对象文件
- 如何对自定义类的向量使用std::find()? 2022-11-07
- 近似搜索的工作原理 2021-01-01
- 一起使用 MPI 和 OpenCV 时出现分段错误 2022-01-01
- 使用/clr 时出现 LNK2022 错误 2022-01-01
- 静态初始化顺序失败 2022-01-01
- STL 中有 dereference_iterator 吗? 2022-01-01
- Stroustrup 的 Simple_window.h 2022-01-01
- 与 int by int 相比,为什么执行 float by float 矩阵乘法更快? 2021-01-01
- 从python回调到c++的选项 2022-11-16
- C++ 协变模板 2021-01-01