Muzz
15th February 2008, 00:10
Hello everybody,
Im busy with a new/old project that has to been used QT 4.2.0, I use the follow software to develop with QT:
Microsoft Visual C++ 2005 Express - V: 8.0.50727.42
QT 4.2.0 (Installed in D:\qt-win-4.2.0)
The follow environment variables in Windows XP are set:
QMAKESPEC => win32-msvc2005
PATH => D:\qt-win-4.2.0\lib;D:\qt-win-4.2.0\bin
In Microsoft Visual C++ 2005 Express in the Options dialog, At Project and Solutions, VC++ Directories, The follow directories are set:
LIBRARY: D:\qt-win-4.2.0\lib
(Visual Studio makefile returns: d:\qt-win-4.2.0\lib\qtmain.lib d:\qt-win-4.2.0\lib\QtGui4.lib d:\qt-win-4.2.0\lib\QtCore4.lib)
I've used a community patch for 4.2.X to configure this QT Release to enable it in Visual Studio 2005 Express, The follow problem when I try to compile my project in an release, It fails on many things that I do not follow.
I've got the follow directory structure:
src/images (My images I use within my program)
src/include (My included files to refer to in my source)
src/xmpp (Some connection header files and CPP's, Used by source)
src/ itselfs has several .h and .cpp and .ui files. The next few files are differents like my generated .PRO file:
################################################## ####################
# Automatically generated by qmake (2.01a) vr 15. feb 00:42:54 2008
################################################## ####################
TEMPLATE = app
TARGET =
DEPENDPATH += . include xmpp
INCLUDEPATH += .
# Input
HEADERS += aboutdialog.h \
accountdialog.h \
appdatachannel.h \
chatdialog.h \
editgroupsdialog.h \
eventqueue.h \
generaloptionswidget.h \
loginpane.h \
mainwindow.h \
MinimizeToTray.h \
nodetabwidget.h \
nodetreewidget.h \
options.h \
optionsdialog.h \
pluginmanager.h \
pluginoptionswidget.h \
rosterdomainview.h \
rostergroupview.h \
rosteronlineview.h \
rosteroptionswidget.h \
rosterpane.h \
rosterplugin.h \
rosterview.h \
selectcontactdialog.h \
systemmsgdialog.h \
useraccount.h \
include/conversation.h \
include/node.h \
include/plugin.h \
include/roster.h \
include/socket.h \
include/urihandler.h \
include/user.h \
xmpp/dnssrv.h \
xmpp/httpsproxy.h \
xmpp/iqauth.h \
xmpp/jabberauth.h \
xmpp/proxy.h \
xmpp/registerauth.h \
xmpp/saslmd5.h \
xmpp/saslmech.h \
xmpp/saslplain.h \
xmpp/socks5proxy.h \
xmpp/sslsocket.h \
xmpp/xmppauth.h \
xmpp/xmppstream.h \
xmpp/xmppversion.h \
../plugins/privacy/privacy.h \
../plugins/filetransfer/filetransfer.h
FORMS += aboutdialog.ui \
accountdialog.ui \
editgroupsdialog.ui \
generaloptionswidget.ui \
logindialog.ui \
optionsdialog.ui \
pluginoptionswidget.ui \
rosteroptionswidget.ui \
selectcontactdialog.ui \
systemmsgdialog.ui
SOURCES += aboutdialog.cpp \
accountdialog.cpp \
appdatachannel_win.cpp \
chatdialog.cpp \
editgroupsdialog.cpp \
eventqueue.cpp \
generaloptionswidget.cpp \
loginpane.cpp \
main.cpp \
mainwindow.cpp \
MinimizeToTray.cpp \
nodetabwidget.cpp \
nodetreewidget.cpp \
optionsdialog.cpp \
pluginmanager.cpp \
pluginoptionswidget.cpp \
rosterdomainview.cpp \
rostergroupview.cpp \
rosteronlineview.cpp \
rosteroptionswidget.cpp \
rosterpane.cpp \
rosterplugin.cpp \
rosterview.cpp \
selectcontactdialog.cpp \
systemmsgdialog.cpp \
useraccount.cpp \
xmpp/dnssrv.cpp \
xmpp/dnssrv_unix.cpp \
xmpp/dnssrv_win.cpp \
xmpp/httpsproxy.cpp \
xmpp/iqauth.cpp \
xmpp/proxy.cpp \
xmpp/registerauth.cpp \
xmpp/saslmd5.cpp \
xmpp/saslplain.cpp \
xmpp/socks5proxy.cpp \
xmpp/sslsocket.cpp \
xmpp/xmppauth.cpp \
xmpp/xmppstream.cpp \
xmpp/xmppversion.cpp
RESOURCES += lol.qrc
When I open the "Visual Studio 2005 Command Prompt" and type: qmake -project within the src directory, it doesn't fail, Afterwartds, I do qmake -nomoc (That doesnt help since MSVC Solution Explorer gives alot of MOC_.....h or MOC_....Cpp files. When I do qmake -tp vc, it generates the .vcproj and I can open my project.
The follow debug is available from the VSMC IDE:
1>------ Build started: Project: lol, Configuration: Release Win32 ------
1>RCC lol.qrc
1>MOC xmpp\xmppstream.h
1>MOC systemmsgdialog.h
1>MOC xmpp\sslsocket.h
1>MOC xmpp\socks5proxy.h
1>MOC selectcontactdialog.h
1>MOC rosterplugin.h
1>rosterplugin.h(69): Error: Undefined interface
1>Project : error PRJ0019: A tool returned an error code from "MOC rosterplugin.h"
1>lol - 1 error(s), 0 warning(s)
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
nmake in the "Visual Studio 2005 Command Prompt" gives the follow debug:
Microsoft (R) Program Maintenance Utility Version 7.00.8882
Copyright (C) Microsoft Corp 1988-2000. All rights reserved.
nmake -f Makefile.Release
Microsoft (R) Program Maintenance Utility Version 7.00.8882
Copyright (C) Microsoft Corp 1988-2000. All rights reserved.
d:\qt-win-4.2.0\bin\moc.exe -DUNICODE -DQT_LARGEFILE_SUPPORT -DWIN32 -D_
CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE -DQT_DLL -DQT_NO_DEBUG -DQT_
GUI_LIB -DQT_CORE_LIB -DQT_THREAD_SUPPORT -I"D:/qt-win-4.2.0/include/QtCore" -I"
D:/qt-win-4.2.0/include/QtCore" -I"D:/qt-win-4.2.0/include/QtGui" -I"D:/qt-win-4
.2.0/include/QtGui" -I"D:/qt-win-4.2.0/include" -I"." -I"D:/qt-win-4.2.0/include
/ActiveQt" -I"release" -I"." -I"..\..\..\qt-win-4.2.0\mkspecs\win32-msvc2005" ma
inwindow.h -o release\moc_mainwindow.cpp
mainwindow.h(48): Error: Undefined interface
NMAKE : fatal error U1077: 'd:\qt-win-4.2.0\bin\moc.exe' : return code '0x1'
Stop.
NMAKE : fatal error U1077: '"C:\Program Files\Microsoft Visual Studio 8\VC\BIN\n
make.exe"' : return code '0x2'
Stop.
And if I exclude the 'mainwindow.cpp' another file will give an Undefined interface error.
How could I solve this and build my compiled EXE? Thank you.
Im busy with a new/old project that has to been used QT 4.2.0, I use the follow software to develop with QT:
Microsoft Visual C++ 2005 Express - V: 8.0.50727.42
QT 4.2.0 (Installed in D:\qt-win-4.2.0)
The follow environment variables in Windows XP are set:
QMAKESPEC => win32-msvc2005
PATH => D:\qt-win-4.2.0\lib;D:\qt-win-4.2.0\bin
In Microsoft Visual C++ 2005 Express in the Options dialog, At Project and Solutions, VC++ Directories, The follow directories are set:
LIBRARY: D:\qt-win-4.2.0\lib
(Visual Studio makefile returns: d:\qt-win-4.2.0\lib\qtmain.lib d:\qt-win-4.2.0\lib\QtGui4.lib d:\qt-win-4.2.0\lib\QtCore4.lib)
I've used a community patch for 4.2.X to configure this QT Release to enable it in Visual Studio 2005 Express, The follow problem when I try to compile my project in an release, It fails on many things that I do not follow.
I've got the follow directory structure:
src/images (My images I use within my program)
src/include (My included files to refer to in my source)
src/xmpp (Some connection header files and CPP's, Used by source)
src/ itselfs has several .h and .cpp and .ui files. The next few files are differents like my generated .PRO file:
################################################## ####################
# Automatically generated by qmake (2.01a) vr 15. feb 00:42:54 2008
################################################## ####################
TEMPLATE = app
TARGET =
DEPENDPATH += . include xmpp
INCLUDEPATH += .
# Input
HEADERS += aboutdialog.h \
accountdialog.h \
appdatachannel.h \
chatdialog.h \
editgroupsdialog.h \
eventqueue.h \
generaloptionswidget.h \
loginpane.h \
mainwindow.h \
MinimizeToTray.h \
nodetabwidget.h \
nodetreewidget.h \
options.h \
optionsdialog.h \
pluginmanager.h \
pluginoptionswidget.h \
rosterdomainview.h \
rostergroupview.h \
rosteronlineview.h \
rosteroptionswidget.h \
rosterpane.h \
rosterplugin.h \
rosterview.h \
selectcontactdialog.h \
systemmsgdialog.h \
useraccount.h \
include/conversation.h \
include/node.h \
include/plugin.h \
include/roster.h \
include/socket.h \
include/urihandler.h \
include/user.h \
xmpp/dnssrv.h \
xmpp/httpsproxy.h \
xmpp/iqauth.h \
xmpp/jabberauth.h \
xmpp/proxy.h \
xmpp/registerauth.h \
xmpp/saslmd5.h \
xmpp/saslmech.h \
xmpp/saslplain.h \
xmpp/socks5proxy.h \
xmpp/sslsocket.h \
xmpp/xmppauth.h \
xmpp/xmppstream.h \
xmpp/xmppversion.h \
../plugins/privacy/privacy.h \
../plugins/filetransfer/filetransfer.h
FORMS += aboutdialog.ui \
accountdialog.ui \
editgroupsdialog.ui \
generaloptionswidget.ui \
logindialog.ui \
optionsdialog.ui \
pluginoptionswidget.ui \
rosteroptionswidget.ui \
selectcontactdialog.ui \
systemmsgdialog.ui
SOURCES += aboutdialog.cpp \
accountdialog.cpp \
appdatachannel_win.cpp \
chatdialog.cpp \
editgroupsdialog.cpp \
eventqueue.cpp \
generaloptionswidget.cpp \
loginpane.cpp \
main.cpp \
mainwindow.cpp \
MinimizeToTray.cpp \
nodetabwidget.cpp \
nodetreewidget.cpp \
optionsdialog.cpp \
pluginmanager.cpp \
pluginoptionswidget.cpp \
rosterdomainview.cpp \
rostergroupview.cpp \
rosteronlineview.cpp \
rosteroptionswidget.cpp \
rosterpane.cpp \
rosterplugin.cpp \
rosterview.cpp \
selectcontactdialog.cpp \
systemmsgdialog.cpp \
useraccount.cpp \
xmpp/dnssrv.cpp \
xmpp/dnssrv_unix.cpp \
xmpp/dnssrv_win.cpp \
xmpp/httpsproxy.cpp \
xmpp/iqauth.cpp \
xmpp/proxy.cpp \
xmpp/registerauth.cpp \
xmpp/saslmd5.cpp \
xmpp/saslplain.cpp \
xmpp/socks5proxy.cpp \
xmpp/sslsocket.cpp \
xmpp/xmppauth.cpp \
xmpp/xmppstream.cpp \
xmpp/xmppversion.cpp
RESOURCES += lol.qrc
When I open the "Visual Studio 2005 Command Prompt" and type: qmake -project within the src directory, it doesn't fail, Afterwartds, I do qmake -nomoc (That doesnt help since MSVC Solution Explorer gives alot of MOC_.....h or MOC_....Cpp files. When I do qmake -tp vc, it generates the .vcproj and I can open my project.
The follow debug is available from the VSMC IDE:
1>------ Build started: Project: lol, Configuration: Release Win32 ------
1>RCC lol.qrc
1>MOC xmpp\xmppstream.h
1>MOC systemmsgdialog.h
1>MOC xmpp\sslsocket.h
1>MOC xmpp\socks5proxy.h
1>MOC selectcontactdialog.h
1>MOC rosterplugin.h
1>rosterplugin.h(69): Error: Undefined interface
1>Project : error PRJ0019: A tool returned an error code from "MOC rosterplugin.h"
1>lol - 1 error(s), 0 warning(s)
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
nmake in the "Visual Studio 2005 Command Prompt" gives the follow debug:
Microsoft (R) Program Maintenance Utility Version 7.00.8882
Copyright (C) Microsoft Corp 1988-2000. All rights reserved.
nmake -f Makefile.Release
Microsoft (R) Program Maintenance Utility Version 7.00.8882
Copyright (C) Microsoft Corp 1988-2000. All rights reserved.
d:\qt-win-4.2.0\bin\moc.exe -DUNICODE -DQT_LARGEFILE_SUPPORT -DWIN32 -D_
CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE -DQT_DLL -DQT_NO_DEBUG -DQT_
GUI_LIB -DQT_CORE_LIB -DQT_THREAD_SUPPORT -I"D:/qt-win-4.2.0/include/QtCore" -I"
D:/qt-win-4.2.0/include/QtCore" -I"D:/qt-win-4.2.0/include/QtGui" -I"D:/qt-win-4
.2.0/include/QtGui" -I"D:/qt-win-4.2.0/include" -I"." -I"D:/qt-win-4.2.0/include
/ActiveQt" -I"release" -I"." -I"..\..\..\qt-win-4.2.0\mkspecs\win32-msvc2005" ma
inwindow.h -o release\moc_mainwindow.cpp
mainwindow.h(48): Error: Undefined interface
NMAKE : fatal error U1077: 'd:\qt-win-4.2.0\bin\moc.exe' : return code '0x1'
Stop.
NMAKE : fatal error U1077: '"C:\Program Files\Microsoft Visual Studio 8\VC\BIN\n
make.exe"' : return code '0x2'
Stop.
And if I exclude the 'mainwindow.cpp' another file will give an Undefined interface error.
How could I solve this and build my compiled EXE? Thank you.