1.Download GCC 4.3.2: http://www.tdragon.net/recentgcc/ click "TDM/MinGW Installer 1.808.3" to download and install;
2.Download Qt 4.4.3: ftp://ftp.trolltech.com/qt/source/qt....4.3-mingw.exe and install it. You will get a warning, just click OK to ignore;
3.In your System Environment's PATH, add YourMinGWDir\bin and YourQtDir\4.4.3\bin;
4.There are some bugs in Qt 4.4.3. Please fix them:
(1) Qt\4.4.3\src\corelib\arch\qatomic_windows.h: check line 386-392, they should be:
extern “C†{
__declspec(dllimport) long __stdcall InterlockedCompareExchange(long *, long, long);
__declspec(dllimport) long __stdcall InterlockedIncrement(long *);
__declspec(dllimport) long __stdcall InterlockedDecrement(long *);
__declspec(dllimport) long __stdcall InterlockedExchange(long *, long);
__declspec(dllimport) long __stdcall InterlockedExchangeAdd(long *, long);
}
Please modify them like below:
extern “C†{
__declspec(dllimport) long __stdcall InterlockedCompareExchange(volatile long *, long, long);
__declspec(dllimport) long __stdcall InterlockedIncrement(volatile long *);
__declspec(dllimport) long __stdcall InterlockedDecrement(volatile long *);
__declspec(dllimport) long __stdcall InterlockedExchange(volatile long *, long);
__declspec(dllimport) long __stdcall InterlockedExchangeAdd(volatile long *, long);
}
(2) Qt\4.4.3\src\corelib\io\qfsfileengine_win.cpp: check line 67-68, they should be:
#define SECURITY_WIN32
#include <security.h>
Add a line between them #include <subauth.h>, like these lines below:
#define SECURITY_WIN32
#include <subauth.h>
#include <security.h>
(3) Qt\4.4.3\src\gui\inputmethod\qwininputcontext_win. cpp: check line 500, it should be:
bool QWinInputContext::endComposition()
Please add a line above it: extern bool qt_sendSpontaneousEvent(QObject *, QEvent *); ,like these lines blow:
extern bool qt_sendSpontaneousEvent(QObject *, QEvent *);
bool QWinInputContext::endComposition()
5.OK. It's time to compile. Click "Start"->"Qt by Nokia v4.4.3 (OpenSource)"->"Qt 4.4.3 Command Prompt", then enter "configure -debug-and-release -plugin-sql-sqlite -plugin-sql-odbc -qt-libpng -qt-libjpeg" and enter to configure. After several minutes, configure will done. And enter "mingw32-make" and enter to compile. It may take about 3 hours to make. It should take 4G harddisk place.
Bookmarks