我正在使用Visual Studio 2017和Windows 10构建Qt 5.9.1。我使用了VS 2017的x64 Native Tools命令提示符和此配置
configure -mp -opensource -prefix E:\Library\qt\5.9.1\msvc_x64 -debug-and-release -nomake tests -nomake examples -qt-zlib -qt-libpng -qt-libjpeg
并且运行了nmake,但是我收到了这个错误:
[8496/18067] CXX obj/cc/base/base/histograms.ob
注意: 包含文件: E:\Library\qt-everywhere-opensource-src-5.9.1\qtwebengine\src\3rdparty\chromium\cc/base/histograms.h
注意: 包含文件: E:\Library\qt-everywhere-opensource-src-5.9.1\qtwebengine\src\3rdparty\chromium\base/compiler_specific.h
注意: 包含文件: E:\Library\qt-everywhere-opensource-src-5.9.1\qtwebengine\src\3rdparty\chromium\build/build_config.h
注意: 包含文件: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\sal.h
注意: 包含文件: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\ConcurrencySal.h
注意: 包含文件: E:\Library\qt-everywhere-opensource-src-5.9.1\qtwebengine\src\3rdparty\chromium\base/macros.h
注意: 包含文件: C:\Program Files (x86)\Windows Kits\10\include\10.0.15063.0\ucrt\stddef.h
注意: 包含文件: C:\Program Files (x86)\Windows Kits\10\include\10.0.15063.0\ucrt\corecrt.h
注意: 包含文件: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\vcruntime.h
注意: 包含文件: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\vadefs.h
注意: 包含文件: E:\Library\qt-everywhere-opensource-src-5.9.1\qtwebengine\src\3rdparty\chromium\base/metrics/histogram_base.h
注意: 包含文件: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\limits.h
注意: 包含文件: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\vcruntime.h
注意: 包含文件: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\stdint.h
....
很多包括
....
注意: 包含文件: E:\Library\qt-everywhere-opensource-src-5.9.1\qtwebengine\src\3rdparty\chromium\base/metrics/histogram_macros.h
注意: 包含文件: E:\Library\qt-everywhere-opensource-src-5.9.1\qtwebengine\src\3rdparty\chromium\base/metrics/histogram_samples.h
注意: 包含文件: E:\Library\qt-everywhere-opensource-src-5.9.1\qtwebengine\src\3rdparty\chromium\base/metrics/histogram_macros_internal.h
注意: 包含文件: E:\Library\qt-everywhere-opensource-src-5.9.1\qtwebengine\src\3rdparty\chromium\base/metrics/sparse_histogram.h
注意: 包含文件: E:\Library\qt-everywhere-opensource-src-5.9.1\qtwebengine\src\3rdparty\chromium\base/synchronization/lock.h
注意: 包含文件: E:\Library\qt-everywhere-opensource-src-5.9.1\qtwebengine\src\3rdparty\chromium\base/synchronization/lock_impl.h
注意: 包含文件: E:\Library\qt-everywhere-opensource-src-5.9.1\qtwebengine\src\3rdparty\chromium\base/threading/platform_thread.h
注意: 包含文件: E:\Library\qt-everywhere-opensource-src-5.9.1\qtwebengine\src\3rdparty\chromium\base/metrics/histogram_macros_local.h
注意: 包含文件: E:\Library\qt-everywhere-opensource-src-5.9.1\qtwebengine\src\3rdparty\chromium\base/strings/stringprintf.h
注意: 包含文件: E:\Library\qt-everywhere-opensource-src-5.9.1\qtwebengine\src\3rdparty\chromium\base/timer/elapsed_timer.h
注意: 包含文件: E:\Library\qt-everywhere-opensource-src-5.9.1\qtwebengine\src\3rdparty\chromium\cc/base/cc_export.h
注意: 包含文件: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\algorithm
注意: 包含文件: E:\Library\qt-everywhere-opensource-src-5.9.1\qtwebengine\src\3rdparty\chromium\base/lazy_instance.h
注意: 包含文件: E:\Library\qt-everywhere-opensource-src-5.9.1\qtwebengine\src\3rdparty\chromium\base/debug/leak_annotations.h
注意: 包含文件: E:\Library\qt-everywhere-opensource-src-5.9.1\qtwebengine\src\3rdparty\chromium\base/memory/aligned_memory.h
注意: 包含文件: E:\Library\qt-everywhere-opensource-src-5.9.1\qtwebengine\src\3rdparty\chromium\base/threading/thread_restrictions.h
ninja: build stopped: subcommand failed.
NMAKE : fatal error U1077: “call”: 返回代码“0x1”
Stop.
NMAKE : fatal error U1077: “"C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.10.25017\bin\HostX64\x64\nmake.exe"”: 返回代码“0x2”
Stop.
NMAKE : fatal error U1077: “(”: 返回代码“0x2”
Stop.
NMAKE : fatal error U1077: “cd”: 返回代码“0x2”
Stop.
NMAKE : fatal error U1077: “cd”: 返回代码“0x2”
Stop.
NMAKE : fatal error U1077: “cd”: 返回代码“0x2”
Stop.
我不知道发生了什么以及如何解决这个问题。
更新: 我尝试了Jom,它给出了类似的结果,但是在不同的位置:
[6/9573] CXX obj/cc/base/base/invalidation_region.obj
注意: 包含文件: E:\Library\qt-everywhere-opensource-src-5.9.1\qtwebengine\src\3rdparty\chromium\cc/base/invalidation_region.h
注意: 包含文件: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\vector
注意: 包含文件: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\xmemory
注意: 包含文件: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\xmemory0
注意: 包含文件: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\cstdint
注意: 包含文件: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\yvals.h
注意: 包含文件: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\xkeycheck.h
注意: 包含文件: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\crtdefs.h
注意: 包含文件: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\vcruntime.h
注意: 包含文件: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\sal.h
注意: 包含文件: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\ConcurrencySal.h
注意: 包含文件: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\vadefs.h
注意: 包含文件: C:\Program Files (x86)\Windows Kits\10\include\10.0.15063.0\ucrt\corecrt.h
注意: 包含文件: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\vcruntime.h
注意: 包含文件: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\use_ansi.h
注意: 包含文件: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\stdint.h
注意: 包含文件: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\vcruntime.h
注意: 包含文件: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\cstdlib
...
...
注意: 包含文件: C:\Program Files (x86)\Windows Kits\10\include\10.0.15063.0\um\ime_cmodes.h
注意: 包含文件: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\intrin.h
注意: 包含文件: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\vcruntime.h
注意: 包含文件: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\setjmp.h
注意: 包含文件: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\vcruntime.h
注意: 包含文件: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\immintrin.h
注意: 包含文件: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\wmmintrin.h
注意: 包含文件: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\nmmintrin.h
注意: 包含文件: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\smmintrin.h
注意: 包含文件: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\tmmintrin.h
注意: 包含文件: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\pmmintrin.h
注意: 包含文件: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\emmintrin.h
注意: 包含文件: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\zmmintrin.h
注意: 包含文件: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.10.25017\include\ammintrin.h
注意: 包含文件: E:\Library\qt-everywhere-opensource-src-5.9.1\qtwebengine\src\3rdparty\chromium\base/strings/string_piece.h
注意: 包含文件: E:\Library\qt-everywhere-opensource-src-5.9.1\qtwebengine\src\3rdparty\chromium\base/strings/string16.h
注意: 包含文件: E:\Library\qt-everywhere-opensource-src-5.9.1\qtwebengine\src\3rdparty\chromium\base/time/time.h
注意: 包含文件: C:\Program Files (x86)\Windows Kits\10\include\10.0.15063.0\ucrt\time.h
注意: 包含文件: E:\Library\qt-everywhere-opensource-src-5.9.1\qtwebengine\src\3rdparty\chromium\base/metrics/histogram_macros.h
注意: 包含文件: E:\Library\qt-everywhere-opensource-src-5.9.1\qtwebengine\src\3rdparty\chromium\base/metrics/histogram.h
注意: 包含文件: E:\Library\qt-everywhere-opensource-src-5.9.1\qtwebengine\src\3rdparty\chromium\base/metrics/histogram_macros_internal.h
注意: 包含文件: E:\Library\qt-everywhere-opensource-src-5.9.1\qtwebengine\src\3rdparty\chromium\base/metrics/sparse_histogram.h
注意: 包含文件: E:\Library\qt-everywhere-opensource-src-5.9.1\qtwebengine\src\3rdparty\chromium\base/metrics/histogram_samples.h
注意: 包含文件: E:\Library\qt-everywhere-opensource-src-5.9.1\qtwebengine\src\3rdparty\chromium\base/synchronization/lock.h
注意: 包含文件: E:\Library\qt-everywhere-opensource-src-5.9.1\qtwebengine\src\3rdparty\chromium\base/synchronization/lock_impl.h
注意: 包含文件: E:\Library\qt-everywhere-opensource-src-5.9.1\qtwebengine\src\3rdparty\chromium\base/threading/platform_thread.h
注意: 包含文件: E:\Library\qt-everywhere-opensource-src-5.9.1\qtwebengine\src\3rdparty\chromium\base/metrics/histogram_macros_local.h
ninja: build stopped: subcommand failed.
jom: E:\Library\qt-everywhere-opensource-src-5.9.1\qtwebengine\src\core\Makefile.gn_run.Debug [run_ninja] Error 1
jom: E:\Library\qt-everywhere-opensource-src-5.9.1\qtwebengine\src\core\Makefile.gn_run [debug-all] Error 2
jom: E:\Library\qt-everywhere-opensource-src-5.9.1\qtwebengine\src\core\Makefile [sub-gn_run-pro-make_first] Error 2
jom: E:\Library\qt-everywhere-opensource-src-5.9.1\qtwebengine\src\Makefile [sub-core-make_first] Error 2
jom: E:\Library\qt-everywhere-opensource-src-5.9.1\qtwebengine\Makefile [sub-src-make_first] Error 2
jom: E:\Library\qt-everywhere-opensource-src-5.9.1\Makefile [module-qtwebengine-make_first] Error 2
答案 0 :(得分:1)
我遇到了同样的问题。我注意到您像我一样将VS语言设置为中文。我把VS语言改成英文,重启终端后就解决了。