I want to create a Windows DLL that links statically against the QT libraries.
To do that, I have done the following:
-> in mkspecs/win32-msvc2008/qmake.conf changed the debug and release flags from -MDd and -MD to -MTd and -MT respectively. (s/-MT/-MD/g)
-> configure qt 4.6.2: "configure -static -nomake examples -nomake demos" and compile it
-> In my dll pro file:
TEMPLATE = lib
CONFIG += dll

I get a lot of errors at link time:
error LNK2019: unresolved external symbol "__declspec(dllimport) public: bool __thiscall QString:perator==(char const *)const "

This leads me to believe that qmake is setting up makefiles that cause my dll to attempt linking against QT dlls.
An additional clue is the invocation to moc as well as the invocation to the compiler has the define for "QT_DLL" which as far as I know is to be used only when linking against QT dlls.
e.g.:
==============
qt-everywhere-opensource-src-4.6.2-static-x86\bin\moc.exe -DUNICODE -DWIN32 -DQT_LARGEFILE_SUPPORT -DQT_DLL -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -DQT_THREAD_SUPPORT -I"..\..\..\cc\qt-everywhere-opensource-src-4.6.2-static-x86\include\QtCore" -I"..\..\..\cc\qt-everywhere-opensource-src-4.6.2-static-x86\include\QtNetwork" -I"..\..\..\cc\qt-everywhere-opensource-src-4.6.2-static-x86\include\QtGui" -I"..\..\..\cc\qt-everywhere-opensource-src-4.6.2-static-x86\include" -I"." -I"..\..\..\cc\qtservice-2.6_1-opensource-static-x86\src" -I"..\..\..\cc\qt-everywhere-opensource-src-4.6.2-static-x86\include\ActiveQt" -I"debug" -I"..\..\..\cc\qt-everywhere-opensource-src-4.6.2-static-x86\mkspecs\win32-msvc2008" -D_MSC_VER=1500 -DWIN32 ..\..\..\cc\qtservice\src\qtservice_win.cpp -o debug\qtservice_win.moc
==============
and
==============
cl -c -nologo -Zm200 -Zc:wchar_t- -Zi -MTd -GR -EHsc -W3 -w34100 -w34189 -DUNICODE -DWIN32 -DQT_LARGEFILE_SUPPORT -DQT_DLL -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -DQT_THREAD_SUPPORT -I"..\..\..\cc\qt-everywhere-opensource-src-4.6.2-static-x86\include\QtCore" -I"..\..\..\cc\qt-everywhere-opensource-src-4.6.2-static-x86\include\QtNetwork" -I"..\..\..\cc\qt-everywhere-opensource-src-4.6.2-static-x86\include\QtGui" -I"..\..\..\cc\qt-everywhere-opensource-src-4.6.2-static-x86\include" -I"." -I"..\..\..\cc\qtservice-2.6_1-opensource-static-x86\src" -I"..\..\..\cc\qt-everywhere-opensource-src-4.6.2-static-x86\include\ActiveQt" -I"debug" -I"..\..\..\cc\qt-everywhere-opensource-src-4.6.2-static-x86\mkspecs\win32-msvc2008" -Fodebug\ @C:\Users\Uv\AppData\Local\Temp\nm4A73.tmp
main.cpp
==============

I've looked through the questions on this forum as well as the trolltech dev forums - no one else seems to have asked this question.
Any pointer as to what I'm doing wrong?

Thanks in advance,
Yuvraaj