我尝试从 Git repository 构建最新的 Qt在 Windows 上使用以下命令:
mkdir c:\qt\latest
cd c:\qt\latest
git clone git://gitorious.org/qt/qt.git
cd qt
set PATH=%PATH%;c:\qt\latest\qt\bin
configure.exe
不幸的是,配置很早就停止并出现以下错误:
Microsoft (R) Program Maintenance Utility Version 9.00.30729.01 Copyright (C) Microsoft Corporation. All rights reserved.
cl -c -Foproject.obj -W3 -nologo -O2 -I. -Igenerators -Igenerators\unix -Igenerators\win32 -Igenerators\mac -Igenerators\symbian -IC:\Qt\latest\qt\include -IC:\Qt\latest\qt\include\QtCore -IC:\Qt\latest\qt\include -IC:\Qt\latest\qt\include\QtCore -IC:\Qt\latest\qt\src\corelib\global -IC:\Qt\latest\qt\src\corelib\xml -IC:\Qt\latest\qt\mkspecs\win32-msvc2008 -DQT_NO_TEXTCODEC -DQT_NO_UNICODETABLES -DQT_LITE_COMPONENT -DQT_NODLL -DQT_NO_STL -DQT_NO_COMPRESS -DUNICODE -DHAVE_QCONFIG_CPP -DQT_BUILD_QMAKE -DQT_NO_THREAD -DQT_NO_QOBJECT -DQT_NO_GEOM_VARIANT -DQT_NO_DATASTREAM -DQT_NO_PCRE -DQT_BOOTSTRAPPED -DQMAKE_OPENSOURCE_EDITION project.cpp
project.cpp c:\qt\latest\qt\qmake\project.h(45) : fatal error C1083: Cannot open include file: 'qstringlist.h': No such file or directory
NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\BIN\amd64\cl.EXE"' : return code '0x2' Stop.
Building qmake failed, return code 2
我已经从qt.nokia.com上的源代码存档成功构建了Qt(使用相同的命令) .
源代码存档中的代码与Git 存储库之间有什么区别吗? Git 存储库是否已损坏/不完整,或者我是否需要使用其他或不同的命令来构建它?
最佳答案
我有两个想法:
1) 尝试在 c:\qt\latest\qt\子文件夹中构建。例如:
mkdir qt-build
cd qt-build
..\qt\configure
(n)make
2) 如前所述 here也许您需要 Perl。
Make sure that you have Perl installed and that it is working. If configure complains about not being able to find headers. It means that syncqt, a program run by configure could not find your Perl installation.
尝试安装ActivePerl即
关于qt - 如何在 Windows 上从 Git 存储库构建最新的 Qt?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/2084766/