Results 1 to 13 of 13

Thread: help needed with complicated project

  1. #1
    Join Date
    Feb 2008
    Location
    Netherlands, The
    Posts
    18
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows

    Default help needed with complicated project

    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:

    Qt Code:
    1. ######################################################################
    2. # Automatically generated by qmake (2.01a) vr 15. feb 00:42:54 2008
    3. ######################################################################
    4.  
    5. TEMPLATE = app
    6. TARGET =
    7. DEPENDPATH += . include xmpp
    8. INCLUDEPATH += .
    9.  
    10. # Input
    11. HEADERS += aboutdialog.h \
    12. accountdialog.h \
    13. appdatachannel.h \
    14. chatdialog.h \
    15. editgroupsdialog.h \
    16. eventqueue.h \
    17. generaloptionswidget.h \
    18. loginpane.h \
    19. mainwindow.h \
    20. MinimizeToTray.h \
    21. nodetabwidget.h \
    22. nodetreewidget.h \
    23. options.h \
    24. optionsdialog.h \
    25. pluginmanager.h \
    26. pluginoptionswidget.h \
    27. rosterdomainview.h \
    28. rostergroupview.h \
    29. rosteronlineview.h \
    30. rosteroptionswidget.h \
    31. rosterpane.h \
    32. rosterplugin.h \
    33. rosterview.h \
    34. selectcontactdialog.h \
    35. systemmsgdialog.h \
    36. useraccount.h \
    37. include/conversation.h \
    38. include/node.h \
    39. include/plugin.h \
    40. include/roster.h \
    41. include/socket.h \
    42. include/urihandler.h \
    43. include/user.h \
    44. xmpp/dnssrv.h \
    45. xmpp/httpsproxy.h \
    46. xmpp/iqauth.h \
    47. xmpp/jabberauth.h \
    48. xmpp/proxy.h \
    49. xmpp/registerauth.h \
    50. xmpp/saslmd5.h \
    51. xmpp/saslmech.h \
    52. xmpp/saslplain.h \
    53. xmpp/socks5proxy.h \
    54. xmpp/sslsocket.h \
    55. xmpp/xmppauth.h \
    56. xmpp/xmppstream.h \
    57. xmpp/xmppversion.h \
    58. ../plugins/privacy/privacy.h \
    59. ../plugins/filetransfer/filetransfer.h
    60. FORMS += aboutdialog.ui \
    61. accountdialog.ui \
    62. editgroupsdialog.ui \
    63. generaloptionswidget.ui \
    64. logindialog.ui \
    65. optionsdialog.ui \
    66. pluginoptionswidget.ui \
    67. rosteroptionswidget.ui \
    68. selectcontactdialog.ui \
    69. systemmsgdialog.ui
    70. SOURCES += aboutdialog.cpp \
    71. accountdialog.cpp \
    72. appdatachannel_win.cpp \
    73. chatdialog.cpp \
    74. editgroupsdialog.cpp \
    75. eventqueue.cpp \
    76. generaloptionswidget.cpp \
    77. loginpane.cpp \
    78. main.cpp \
    79. mainwindow.cpp \
    80. MinimizeToTray.cpp \
    81. nodetabwidget.cpp \
    82. nodetreewidget.cpp \
    83. optionsdialog.cpp \
    84. pluginmanager.cpp \
    85. pluginoptionswidget.cpp \
    86. rosterdomainview.cpp \
    87. rostergroupview.cpp \
    88. rosteronlineview.cpp \
    89. rosteroptionswidget.cpp \
    90. rosterpane.cpp \
    91. rosterplugin.cpp \
    92. rosterview.cpp \
    93. selectcontactdialog.cpp \
    94. systemmsgdialog.cpp \
    95. useraccount.cpp \
    96. xmpp/dnssrv.cpp \
    97. xmpp/dnssrv_unix.cpp \
    98. xmpp/dnssrv_win.cpp \
    99. xmpp/httpsproxy.cpp \
    100. xmpp/iqauth.cpp \
    101. xmpp/proxy.cpp \
    102. xmpp/registerauth.cpp \
    103. xmpp/saslmd5.cpp \
    104. xmpp/saslplain.cpp \
    105. xmpp/socks5proxy.cpp \
    106. xmpp/sslsocket.cpp \
    107. xmpp/xmppauth.cpp \
    108. xmpp/xmppstream.cpp \
    109. xmpp/xmppversion.cpp
    110. RESOURCES += lol.qrc
    To copy to clipboard, switch view to plain text mode 

    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:
    Qt Code:
    1. 1>------ Build started: Project: lol, Configuration: Release Win32 ------
    2. 1>RCC lol.qrc
    3. 1>MOC xmpp\xmppstream.h
    4. 1>MOC systemmsgdialog.h
    5. 1>MOC xmpp\sslsocket.h
    6. 1>MOC xmpp\socks5proxy.h
    7. 1>MOC selectcontactdialog.h
    8. 1>MOC rosterplugin.h
    9. 1>rosterplugin.h(69): Error: Undefined interface
    10. 1>Project : error PRJ0019: A tool returned an error code from "MOC rosterplugin.h"
    11. 1>lol - 1 error(s), 0 warning(s)
    12. ========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
    To copy to clipboard, switch view to plain text mode 

    nmake in the "Visual Studio 2005 Command Prompt" gives the follow debug:

    Qt Code:
    1. Microsoft (R) Program Maintenance Utility Version 7.00.8882
    2. Copyright (C) Microsoft Corp 1988-2000. All rights reserved.
    3.  
    4. nmake -f Makefile.Release
    5.  
    6. Microsoft (R) Program Maintenance Utility Version 7.00.8882
    7. Copyright (C) Microsoft Corp 1988-2000. All rights reserved.
    8.  
    9. d:\qt-win-4.2.0\bin\moc.exe -DUNICODE -DQT_LARGEFILE_SUPPORT -DWIN32 -D_
    10. CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE -DQT_DLL -DQT_NO_DEBUG -DQT_
    11. GUI_LIB -DQT_CORE_LIB -DQT_THREAD_SUPPORT -I"D:/qt-win-4.2.0/include/QtCore" -I"
    12. D:/qt-win-4.2.0/include/QtCore" -I"D:/qt-win-4.2.0/include/QtGui" -I"D:/qt-win-4
    13. .2.0/include/QtGui" -I"D:/qt-win-4.2.0/include" -I"." -I"D:/qt-win-4.2.0/include
    14. /ActiveQt" -I"release" -I"." -I"..\..\..\qt-win-4.2.0\mkspecs\win32-msvc2005" ma
    15. inwindow.h -o release\moc_mainwindow.cpp
    16. mainwindow.h(48): Error: Undefined interface
    17. NMAKE : fatal error U1077: 'd:\qt-win-4.2.0\bin\moc.exe' : return code '0x1'
    18. Stop.
    19. NMAKE : fatal error U1077: '"C:\Program Files\Microsoft Visual Studio 8\VC\BIN\n
    20. make.exe"' : return code '0x2'
    21. Stop.
    To copy to clipboard, switch view to plain text mode 
    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.
    Microsoft Visual C++ 2005 Express - V: 8.0.50727.42
    QT 4.2.0 Open Source - Installed in D:\qt-win-4.2.0

  2. #2
    Join Date
    Feb 2006
    Location
    Oslo, Norway
    Posts
    6,264
    Thanks
    36
    Thanked 1,519 Times in 1,389 Posts
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows Symbian S60 Maemo/MeeGo

    Default Re: help needed with complicated project

    And what do rosterplugin.h and mainwindow.h look like? Could you attach them?
    J-P Nurmi

  3. #3
    Join Date
    Feb 2008
    Location
    Netherlands, The
    Posts
    18
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows

    Default Re: help needed with complicated project

    Hi,

    The file's are Attached to this post.

    Thank you.
    Attached Files Attached Files
    Microsoft Visual C++ 2005 Express - V: 8.0.50727.42
    QT 4.2.0 Open Source - Installed in D:\qt-win-4.2.0

  4. #4
    Join Date
    Feb 2006
    Location
    Oslo, Norway
    Posts
    6,264
    Thanks
    36
    Thanked 1,519 Times in 1,389 Posts
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows Symbian S60 Maemo/MeeGo

    Default Re: help needed with complicated project

    Hmm, Q_INTERFACES() is used when implementing plugins but you're compiling everything in one pass. Do you have the original .pro file(s)?
    J-P Nurmi

  5. #5
    Join Date
    Feb 2008
    Location
    Netherlands, The
    Posts
    18
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows

    Default Re: help needed with complicated project

    Yes, They are posted in this reply,

    • The linq.pro is in /
    • The src.pro is in /src/
    • The liblinq.pro is in /src/liblinq/
    • The libidn.pro is in /src/libidn/
    Attached Files Attached Files
    Microsoft Visual C++ 2005 Express - V: 8.0.50727.42
    QT 4.2.0 Open Source - Installed in D:\qt-win-4.2.0

  6. #6
    Join Date
    Feb 2006
    Location
    Oslo, Norway
    Posts
    6,264
    Thanks
    36
    Thanked 1,519 Times in 1,389 Posts
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows Symbian S60 Maemo/MeeGo

    Default Re: help needed with complicated project

    So, what happens if you build the project with its original .pro files (eg. without using "qmake -project")?
    J-P Nurmi

  7. #7
    Join Date
    Feb 2008
    Location
    Netherlands, The
    Posts
    18
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows

    Default Re: help needed with complicated project

    I open the "Visual Studio 2005 Command Prompt" and go to the follow directory "D:/lol", In that directory I've the follow directories "src" but I do not go to that directory because there is linq.pro in "D:/lol".

    When I do qmake nothing happends, but generated the MAKEFILE.
    D:\hyves\src>qmake

    D:\hyves\src>

    And when I do nmake, The follow appears:
    Qt Code:
    1. Microsoft (R) Program Maintenance Utility Version 7.00.8882
    2. Copyright (C) Microsoft Corp 1988-2000. All rights reserved.
    3.  
    4. cd zlib && D:\qt-win-4.2.0\bin\qmake.exe zlib.pro -win32 -o Makefile
    5. cd zlib && nmake -f Makefile
    6.  
    7. Microsoft (R) Program Maintenance Utility Version 7.00.8882
    8. Copyright (C) Microsoft Corp 1988-2000. All rights reserved.
    9.  
    10. nmake -f Makefile.Release
    11.  
    12. Microsoft (R) Program Maintenance Utility Version 7.00.8882
    13. Copyright (C) Microsoft Corp 1988-2000. All rights reserved.
    14.  
    15. cl -c -nologo -Zm200 -GS -O2 -MD -DNDEBUG -W3 -DUNICODE -DQT_LARGEFILE_S
    16. UPPORT -DWIN32 -D_CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE -I"." -I".
    17. .\..\..\qt-win-4.2.0\mkspecs\win32-msvc2005" -Forelease\ @C:\DOCUME~1\Rick\LOCAL
    18. S~1\Temp\nm169.tmp
    19. adler32.c
    20. compress.c
    21. crc32.c
    22. deflate.c
    23. example.c
    24. gzio.c
    25. infback.c
    26. inffast.c
    27. inflate.c
    28. inftrees.c
    29. minigzip.c
    30. trees.c
    31. uncompr.c
    32. zutil.c
    33. Generating Code...
    34. lib /NOLOGO /OUT:"release\zlib.lib" @C:\DOCUME~1\Rick\LOCALS~1\Temp\nm16
    35. A.tmp
    36. example.obj : warning LNK4006: _main already defined in minigzip.obj; second def
    37. inition ignored
    38. cd libcrypt && D:\qt-win-4.2.0\bin\qmake.exe libcrypt.pro -win32 -o Make
    39. file
    40. cd libcrypt && nmake -f Makefile
    41.  
    42. Microsoft (R) Program Maintenance Utility Version 7.00.8882
    43. Copyright (C) Microsoft Corp 1988-2000. All rights reserved.
    44.  
    45. nmake -f Makefile.Release
    46.  
    47. Microsoft (R) Program Maintenance Utility Version 7.00.8882
    48. Copyright (C) Microsoft Corp 1988-2000. All rights reserved.
    49.  
    50. cl -c -nologo -Zm200 -GS -O2 -MD -DNDEBUG -GR -EHsc -W3 -DUNICODE -DQT_L
    51. ARGEFILE_SUPPORT -DWIN32 -D_CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE
    52. -I"." -I"..\..\..\qt-win-4.2.0\mkspecs\win32-msvc2005" -Forelease\ @C:\DOCUME~1\
    53. Rick\LOCALS~1\Temp\nm16B.tmp
    54. md5.cpp
    55. cl -c -nologo -Zm200 -GS -O2 -MD -DNDEBUG -W3 -DUNICODE -DQT_LARGEFILE_S
    56. UPPORT -DWIN32 -D_CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE -I"." -I".
    57. .\..\..\qt-win-4.2.0\mkspecs\win32-msvc2005" -Forelease\ @C:\DOCUME~1\Rick\LOCAL
    58. S~1\Temp\nm16C.tmp
    59. sha.c
    60. lib /NOLOGO /OUT:"release\crypt.lib" @C:\DOCUME~1\Rick\LOCALS~1\Temp\nm1
    61. 6D.tmp
    62. cd libidn && D:\qt-win-4.2.0\bin\qmake.exe libidn.pro -win32 -o Makefile
    63.  
    64. cd libidn && nmake -f Makefile
    65.  
    66. Microsoft (R) Program Maintenance Utility Version 7.00.8882
    67. Copyright (C) Microsoft Corp 1988-2000. All rights reserved.
    68.  
    69. nmake -f Makefile.Release
    70.  
    71. Microsoft (R) Program Maintenance Utility Version 7.00.8882
    72. Copyright (C) Microsoft Corp 1988-2000. All rights reserved.
    73.  
    74. cl -c -nologo -Zm200 -GS -O2 -MD -DNDEBUG -W0 -DUNICODE -DQT_LARGEFILE_S
    75. UPPORT -DWIN32 -D_CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE -I"." -I".
    76. " -I"..\..\..\qt-win-4.2.0\mkspecs\win32-msvc2005" -Forelease\ @C:\DOCUME~1\Rick
    77. \LOCALS~1\Temp\nm16E.tmp
    78. nfkc.c
    79. d:\lol\src\libidn\stringprep.h(31) : fatal error C1083: Cannot open include fi
    80. le: 'unistd.h': No such file or directory
    81. profiles.c
    82. d:\lol\src\libidn\stringprep.h(31) : fatal error C1083: Cannot open include fi
    83. le: 'unistd.h': No such file or directory
    84. rfc3454.c
    85. d:\lol\src\libidn\stringprep.h(31) : fatal error C1083: Cannot open include fi
    86. le: 'unistd.h': No such file or directory
    87. stringprep.c
    88. d:\lol\src\libidn\stringprep.h(31) : fatal error C1083: Cannot open include fi
    89. le: 'unistd.h': No such file or directory
    90. toutf8.c
    91. d:\lol\src\libidn\stringprep.h(31) : fatal error C1083: Cannot open include fi
    92. le: 'unistd.h': No such file or directory
    93. Generating Code...
    94. NMAKE : fatal error U1077: 'cl' : return code '0x2'
    95. Stop.
    96. NMAKE : fatal error U1077: '"C:\Program Files\Microsoft Visual Studio 8\VC\BIN\n
    97. make.exe"' : return code '0x2'
    98. Stop.
    99. NMAKE : fatal error U1077: 'cd' : return code '0x2'
    100. Stop.
    To copy to clipboard, switch view to plain text mode 
    Microsoft Visual C++ 2005 Express - V: 8.0.50727.42
    QT 4.2.0 Open Source - Installed in D:\qt-win-4.2.0

  8. #8
    Join Date
    Feb 2006
    Location
    Oslo, Norway
    Posts
    6,264
    Thanks
    36
    Thanked 1,519 Times in 1,389 Posts
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows Symbian S60 Maemo/MeeGo

    Default Re: help needed with complicated project

    Do you have Platform SDK installed?
    J-P Nurmi

  9. #9
    Join Date
    Feb 2008
    Location
    Netherlands, The
    Posts
    18
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows

    Default Re: help needed with complicated project

    Yes I have, That was about 500 Megs. I've double checked right now since I have tested it with an sample source just made to look if windows.h will be included in VS Express.
    Microsoft Visual C++ 2005 Express - V: 8.0.50727.42
    QT 4.2.0 Open Source - Installed in D:\qt-win-4.2.0

  10. #10
    Join Date
    Feb 2006
    Location
    Oslo, Norway
    Posts
    6,264
    Thanks
    36
    Thanked 1,519 Times in 1,389 Posts
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows Symbian S60 Maemo/MeeGo

    Default Re: help needed with complicated project

    J-P Nurmi

  11. #11
    Join Date
    Feb 2008
    Location
    Netherlands, The
    Posts
    18
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows

    Default Re: help needed with complicated project

    Yes, olso checked with making an Win32 example source without ATL ect ect.
    Microsoft Visual C++ 2005 Express - V: 8.0.50727.42
    QT 4.2.0 Open Source - Installed in D:\qt-win-4.2.0

  12. #12
    Join Date
    Feb 2006
    Location
    Oslo, Norway
    Posts
    6,264
    Thanks
    36
    Thanked 1,519 Times in 1,389 Posts
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows Symbian S60 Maemo/MeeGo

    Default Re: help needed with complicated project

    Hmm, is unistd.h available on Windows at all?
    J-P Nurmi

  13. #13
    Join Date
    Feb 2008
    Location
    Netherlands, The
    Posts
    18
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows

    Default Re: help needed with complicated project

    Mhh downloaded a new release of that package that was needed, Working now. Gonne debug other .PRO files in order to compile, Thanks for your help!
    Microsoft Visual C++ 2005 Express - V: 8.0.50727.42
    QT 4.2.0 Open Source - Installed in D:\qt-win-4.2.0

Similar Threads

  1. Importing qt project to an eclipse workspace
    By isahin in forum Installation and Deployment
    Replies: 2
    Last Post: 28th January 2008, 18:00
  2. I need a project opinion.
    By hgedek in forum General Discussion
    Replies: 6
    Last Post: 25th September 2007, 18:54
  3. Qt4 open src mingw from a PC to another
    By nvictor in forum Installation and Deployment
    Replies: 11
    Last Post: 1st May 2007, 17:41

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.