前提:安装好VS2008
一、下载 Qt for Open Source C++ development on Windows (VS2008)
http://get.qt.nokia.com/qt/source/qt-everywhere-opensource-src-4.6.2.zip
二、解压到 G:/qt-everywhere-opensource-src-4.6.2
三、将以下批处理命令保存为:qt-everywhere-opensource-src-4.6.2.bat ,放在G:/qt-everywhere-opensource-src-4.6.2 目录下,双击运行
/
@echo off
rem 设置环境变量
set path=%Path%;C:/Program Files/Microsoft Visual Studio 9.0/VC/;G:/qt-everywhere-opensource-src-4.6.2;G:/qt-everywhere-opensource-src-4.6.2/bin
call vcvarsall.bat
rem 管道命令自动答复configure 的参数选项
(echo;o&echo;y)|configure -platform win32-msvc2008
call setcepaths win32-msvc2008
nmake
nmake clean
enjoy!