按楼上的做法现在可以编译了,可是编译出错,我把例子中的第一个例子找来,编译不能通过,报以下错:
F:\eg>make
make -f Makefile.Debug
make[1]: Entering directory `F:/eg'
g++ -c -g -g -frtti -fexceptions -Wall -DUNICODE -DQT_LARGEFILE_SUPPORT -DQT_DLL
-DQT_CORE_LIB -DQT_GUI_LIB -DQT_THREAD_SUPPORT -DQT_NEEDS_QMAIN -I"C:/Qt/4.0.1/
include/QtGui" -I"C:/Qt/4.0.1/include/QtCore" -I"C:/Qt/4.0.1/include" -I"." -I"C
:/Qt/4.0.1/include/ActiveQt" -I"debug" -I"." -I"C:/Qt/4.0.1/mkspecs/win32-g++" -
o debug\main.o main.cpp
g++ -mthreads -Wl,-enable-stdcall-fixup -Wl,-enable-auto-import -Wl,-enable-runt
ime-pseudo-reloc -Wl,-subsystem,windows -o "debug\eg.exe" debug\main.o -L"C:\Qt
\4.0.1\lib" -lmingw32 -lqtmaind -lQtCored4 -lQtGuid4
c:\qt\Dev-Cpp\bin\..\lib\gcc\mingw32\3.4.2\..\..\..\..\mingw32\bin\ld.exe: canno
t find -lqtmaind
collect2: ld returned 1 exit status
make[1]: *** [debug\eg.exe] Error 1
make[1]: Leaving directory `F:/eg'
make: *** [debug] Error 2