Results 1 to 3 of 3

Thread: Problem building qt embedded for WinCE and VS2005

  1. #1
    Join Date
    Jan 2006
    Location
    Munich, Germany
    Posts
    4,714
    Thanks
    21
    Thanked 418 Times in 411 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows

    Default Problem building qt embedded for WinCE and VS2005

    Hi,

    I am trying to build qt embedded for WinCE (windows mobile professional 6) and I get the following compile error (note, this is VS2005 not the express edition!):
    cl -c -nologo -Zm200 -Zc:wchar_t- -Os -DDEBUG -D_DEBUG -Zi -MDd -W3 -w34100 -w34189 -EHs-c- -DQT_THREAD_SUPPORT -DUNDER_CE -DWINCE -D_WINDOWS -D_UNICODE -DUNICODE -D_WIN32 -DQT_NO_PRINTER -DQT_NO_PRINTDIALOG -DARMV4I -D_ARMV4I_ -Darmv4i -D_ARM_ -DARM -D_M_ARM -DARM -D__arm__ -DQ_OS_WINCE_WM
    -DQT_NO_PRINTER -DQT_NO_PRINTDIALOG -D_WIN32_WCE=0x502 -DQT_NO_CAST_TO_ASCII -DQT_ASCII_CAST_WARNINGS -DQT_MOC_COMPAT -D_USE_MATH_DEFINES -I"..\..\include" -I"tmp" -I"..\..\include\QtCore" -I"c:\Qt\qt-embedded-wince-opensource-src-4.5.0\include\qtmain" -I"tmp\rcc\debug_shared" -I"tmp" -I"..\..\inclu
    de\ActiveQt" -I"tmp\moc\debug_shared" -I"." -I"..\..\mkspecs\wincewm60professional-msvc2005" -Fotmp\obj\debug_shared\ @C:\DOCUME~1\danik\LOCALS~1\Temp\nm322.tmp
    qtmain_win.cpp
    .\qtmain_win.cpp(91) : error C2731: 'WinMain' : function cannot be overloaded
    .\qtmain_win.cpp(86) : see declaration of 'WinMain'
    NMAKE : fatal error U1077: '"C:\Program Files\Microsoft Visual Studio 5\VC\BIN\cl.EXE"' : return code '0x2'
    Stop.
    NMAKE : fatal error U1077: '"C:\Program Files\Microsoft Visual Studio 5\VC\BIN\nmake.exe"' : return code '0x2'
    Stop.
    NMAKE : fatal error U1077: 'cd' : return code '0x2'
    Stop.
    I pretty much followed the README and INSTALL instructions.
    - Installed VS2005
    - Installed WinCE SDK 6 professional.
    - I set the environment variables (the compile does not complain about that)
    - I ran vcvarsall.bat from VS2005 directory.
    - ran configure as follows:
    Qt Code:
    1. configure -platform win32-msvc2005 -xplatform wincewm60professional-msvc2005
    To copy to clipboard, switch view to plain text mode 
    And here is the configure output:
    Environment:
    INCLUDE=
    C:\Program Files\Microsoft Visual Studio 5\VC\ATLMFC\INCLUDE
    C:\Program Files\Microsoft Visual Studio 5\VC\INCLUDE
    C:\Program Files\Microsoft Visual Studio 5\VC\PlatformSDK\include
    C:\Program Files\Microsoft Visual Studio 5\SDK\v2.0\include
    C:\Program Files\Microsoft Visual Studio 5\VC\ce\include
    C:\Program Files\Windows Mobile 6 SDK\PocketPC\Include\Armv4i
    LIB=
    C:\Program Files\Microsoft Visual Studio 5\VC\ATLMFC\LIB
    C:\Program Files\Microsoft Visual Studio 5\VC\LIB
    C:\Program Files\Microsoft Visual Studio 5\VC\PlatformSDK\lib
    C:\Program Files\Microsoft Visual Studio 5\SDK\v2.0\lib
    C:\Program Files\Microsoft Visual Studio 5\VC\ce\lib\armv4i
    C:\Program Files\Windows Mobile 6 SDK\PocketPC\Lib\Armv4i
    PATH=
    C:\Program Files\Microsoft Visual Studio 5\Common7\IDE
    C:\Program Files\Microsoft Visual Studio 5\VC\BIN
    C:\Program Files\Microsoft Visual Studio 5\Common7\Tools
    C:\Program Files\Microsoft Visual Studio 5\Common7\Tools\bin
    C:\Program Files\Microsoft Visual Studio 5\VC\PlatformSDK\bin
    C:\Program Files\Microsoft Visual Studio 5\SDK\v2.0\bin
    C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727
    C:\Program Files\Microsoft Visual Studio 5\VC\VCPackages
    C:\WINDOWS\system32
    C:\WINDOWS
    C:\WINDOWS\System32\Wbem
    C:\Program Files\Microsoft Visual Studio 5\VC\ce\bin\x86_arm
    C:\Qt\qt-embedded-wince-opensource-src-4.5.0\bin
    You are licensed to use this software under the terms of the GNU LGPL version 2.1 or the GNU GPL version 3.
    See C:/Qt/qt-embedded-wince-opensource-src-4.5.0/LICENSE.LGPL
    or C:/Qt/qt-embedded-wince-opensource-src-4.5.0/LICENSE.GPL3

    Configuration:
    dist-config
    large-config
    medium-config
    minimal-config
    small-config
    full-config
    build_all
    debug
    Qt Configuration:
    release
    debug
    zlib
    png
    accessibility
    directshow
    ipv6
    scripttools
    phonon
    phonon-backend
    svg
    minimal-config
    small-config
    medium-config
    large-config
    full-config

    QMAKESPEC...................wincewm60professional-msvc2005 (commandline)
    Architecture................windowsce
    Maketool....................nmake
    Debug symbols...............yes
    Accessibility support.......yes
    STL support.................no
    Exception support...........no
    RTTI support................no
    MMX support.................yes
    3DNOW support...............no
    SSE support.................no
    SSE2 support................no
    IWMMXT support..............yes
    OpenGL support..............no
    Direct3D support............no
    OpenSSL support.............no
    QtDBus support..............no
    QtXmlPatterns support.......no
    Phonon support..............yes
    WebKit support..............no
    QtScriptTools support.......yes
    Graphics System.............raster
    Qt3 compatibility...........no

    Third Party Libraries:
    ZLIB support............qt
    GIF support.............plugin
    TIFF support............plugin
    JPEG support............plugin
    PNG support.............qt
    MNG support.............plugin

    Styles:
    Windows.................yes
    Windows XP..............no
    Windows Vista...........no
    Plastique...............no
    Cleanlooks..............no
    Motif...................no
    CDE.....................no
    Windows CE..............yes
    Windows Mobile..........yes

    Sql Drivers:
    ODBC....................no
    MySQL...................no
    OCI.....................no
    PostgreSQL..............no
    TDS.....................no
    DB2.....................no
    SQLite..................plugin (qt)
    SQLite2.................no
    InterBase...............no

    Sources are in..............C:\Qt\qt-embedded-wince-opensource-src-4.5.0
    Build is done in............C:\Qt\qt-embedded-wince-opensource-src-4.5.0
    Install prefix..............
    Headers installed to........
    Libraries installed to......
    Plugins installed to........
    Binaries installed to.......
    Docs installed to...........
    Data installed to...........
    Translations installed to...
    Examples installed to.......
    Demos installed to..........

    Using c runtime detection...yes
    (Please note that "C:\Program Files\Microsoft Visual Studio 5" is my naming for the V2005 folder, its not really VS5!)

    And yet, it seems WinMain gets defined somewhere else in addition to where it needs to be defined.
    Can any one see what I might be doing wrong, or may be you can see in the compile line any missing defines or defines that do not belong there?

    Thanks in advance.
    ==========================signature=============== ==================
    S.O.L.I.D principles (use them!):
    https://en.wikipedia.org/wiki/SOLID_...iented_design)

    Do you write clean code? - if you are TDD'ing then maybe, if not, your not writing clean code.

  2. #2
    Join Date
    Jan 2006
    Location
    Munich, Germany
    Posts
    4,714
    Thanks
    21
    Thanked 418 Times in 411 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows

    Default Re: Problem building qt embedded for WinCE and VS2005

    Hmm...
    It just occurred to me I might understood something very basic wrong, hopefully some one here can answer this:
    What the first post describes was done on windows XP.
    I assumed, that building qtopia for wince on XP, will allow me to develop on my XP, and then deploy it on WinCE (I am aware that the target needs Qt installed on it as well for the application to run) - I thought that I will just need to configure my project setting in VS2005 to compile to a WinCE target...
    Is my assumption correct?
    Or do I really need to develop (reads: compile) on my target device? (and thus the whole build process needs to be done on the target device for that)

    Otherwise I have real trouble figuring out why my build wont compile...

    Thanks.
    ==========================signature=============== ==================
    S.O.L.I.D principles (use them!):
    https://en.wikipedia.org/wiki/SOLID_...iented_design)

    Do you write clean code? - if you are TDD'ing then maybe, if not, your not writing clean code.

  3. #3
    Join Date
    Jan 2009
    Location
    New Zealand
    Posts
    29
    Thanks
    3
    Thanked 1 Time in 1 Post
    Qt products
    Qt4 Qt/Embedded
    Platforms
    Windows

    Default Re: Problem building qt embedded for WinCE and VS2005

    Just checking (this was my problem): Did you download the WinCE package or the Windows installer? The reason my Qt came up with the same error was because the installer doesn't support WinCE - you have to download a separate package.

Similar Threads

  1. LNK2005 error in VS2005 when statically building Qt App
    By pkloc in forum General Programming
    Replies: 9
    Last Post: 2nd July 2011, 01:36
  2. VS2005 Deployment Problem
    By musaulker in forum Installation and Deployment
    Replies: 6
    Last Post: 20th July 2008, 19:43

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.