• 1921阅读
  • 2回复

[提问]求助 Qt 的安装异常 [复制链接]

上一主题 下一主题
离线linkstark
 

只看楼主 倒序阅读 楼主  发表于: 2021-02-13
安装的vs2017,后面安装了Qt,创建了一个空白C++ application,选择的msvc2017 x64编译器,报错如下,找不到iostream,以前用的vs2019可以编译hello world(用2019安装的msvc2017编译器,手动配置的编译器、安装的sdk),后面卸载了换成了2017,但是现在报错,连这个最简单的iostream都找不到,百度了许久无果,连stack overflow也去过了,也没有办法解决,只好来求助各位大佬了。
。。。\Projects\Qt\untitled\main.cpp:1: error: C1083: 无法打开包括文件: “iostream”: No such file or directory
离线linkstark

只看该作者 1楼 发表于: 2021-02-13
编译输出如下:

00:12:16: 为项目untitled执行步骤 ...
00:12:16: 配置没有改变, 跳过 qmake 步骤。
00:12:16: 正在启动 "C:\Qt\Qt5.14.2\Tools\QtCreator\bin\jom.exe"

    C:\Qt\Qt5.14.2\Tools\QtCreator\bin\jom.exe -f Makefile.Debug
    cl -c -nologo -Zc:wchar_t -FS -Zc:rvalueCast -Zc:inline -Zc:strictStrings -Zc:throwingNew -Zc:referenceBinding -Zc:__cplusplus -Zi -MDd -W3 -w34100 -w34189 -w44996 -w44456 -w44457 -w44458 -wd4577 -wd4467 -EHsc /Fddebug\untitled.vc.pdb -DUNICODE -D_UNICODE -DWIN32 -D_ENABLE_EXTENDED_ALIGNED_STORAGE -DWIN64 -DQT_QML_DEBUG -I..\..\untitled -I. -IC:\Qt\Qt5.14.2\5.14.2\msvc2017_64\mkspecs\win32-msvc -Fodebug\ @C:\Users\...\AppData\Local\Temp\main.obj.17168.0.jom
main.cpp
..\main.cpp(1): fatal error C1083: 无法打开包括文件: “iostream”: No such file or directory
jom: C:\Users\...\Desktop\Projects\Qt\untitled\build-untitled-Desktop_Qt_5_14_2_MSVC2017_64bit-Debug\Makefile.Debug [debug\main.obj] Error 2
jom: C:\Users\...\Desktop\Projects\Qt\untitled\build-untitled-Desktop_Qt_5_14_2_MSVC2017_64bit-Debug\Makefile [debug] Error 2
00:12:17: 进程"C:\Qt\Qt5.14.2\Tools\QtCreator\bin\jom.exe"退出,退出代码 2 。
Error while building/deploying project untitled (kit: Desktop Qt 5.14.2 MSVC2017 64bit)
The kit Desktop Qt 5.14.2 MSVC2017 64bit has configuration issues which might be the root cause for this problem.
When executing step "Make"
00:12:17: Elapsed time: 00:01.
离线fsu0413

只看该作者 2楼 发表于: 2021-02-14
VS2017 IDE里好用吗?
命令行里好用吗?

VS2019安装VS2017编译器可能会有各种各样的问题,建议使用VS2017安装。
快速回复
限100 字节
 
上一个 下一个