By now I've recompiled Qt for various source packages and for various builds, but I just can't seem Qt to compile for a mobile device. (It compiles fine for Win32).
Here's what I did:
- Installed the latest Qt package for msvc2008 in C:\Qt\4.6.2\ and also ActivePerl.
- Created new folder in C:\Qt\4.6.2-mobile\
- Created a \bin in that folder and added it to PATH sys environment variable (My Computer... etc)
- Opened up MSVS Command Prompt, and cd'd to C:\Qt\4.6.2-mobile
- ran:
Qt Code:
C:\Qt\4.6.2\configure -platform win32-msvc2008 -xplatform wincewm60professional-msvc2008 -nomake examples -nomake demos -no-qt3support -no-webkit -no-phonon -no-phonon-backend -releaseTo copy to clipboard, switch view to plain text mode- ran:
Qt Code:
setcepaths wincewm60professional-msvc2008 && nmakeTo copy to clipboard, switch view to plain text mode- Compiles successfully
- Now I go to my existing project (G:\Qt\winceapp\WinCEApp.pro, a simple QMainWindow program with 1 button that does nothing) and open up MSVS Command prompt, cd to it, and type (the manual method to compile for WinCE according to the docs). Compiles succesfully... but when I copy that + QtCore.dll + QtGui.dll (from C:\Qt\4.6.2-mobile\libs) I get that it's not a valid Pocket PC application.
- So I try "qmake -tp vc". I get a .vcproj file. Open that, go to Configuration Manager, change to "Release", create a <New> solution platform (copied settings from Win32) and changed to "Windows Mobile 6 Professional SDK (ARMV4I)" (check box checked).
- Press F5, and get a bunch of errors:
Qt Code:
1>------ Rebuild All started: Project: WinCEApp, Configuration: Release Windows Mobile 6 Professional SDK (ARMV4I) ------ 1>Deleting intermediate and output files for project 'WinCEApp', configuration 'Release|Windows Mobile 6 Professional SDK (ARMV4I)' 1>MOC mainwindow.h 1>UIC mainwindow.ui 1>Compiling... 1>main.cpp 1>c:\qt\4.6.2\include\qtcore\../../src/corelib/arch/qatomic_windows.h(167) : warning C4163: '_InterlockedExchangeAdd64' : not available as an intrinsic function 1>C:\Program Files\Microsoft Visual Studio 9.0\VC\ce\include\crtdefs.h(106) : fatal error C1189: #error : ERROR: Use of C runtime library internal header file. 1>moc_mainwindow.cpp 1>c:\qt\4.6.2\include\qtcore\../../src/corelib/arch/qatomic_windows.h(167) : warning C4163: '_InterlockedExchangeAdd64' : not available as an intrinsic function 1>C:\Program Files\Microsoft Visual Studio 9.0\VC\ce\include\crtdefs.h(106) : fatal error C1189: #error : ERROR: Use of C runtime library internal header file. 1>mainwindow.cpp 1>c:\qt\4.6.2\include\qtcore\../../src/corelib/arch/qatomic_windows.h(167) : warning C4163: '_InterlockedExchangeAdd64' : not available as an intrinsic function 1>C:\Program Files\Microsoft Visual Studio 9.0\VC\ce\include\crtdefs.h(106) : fatal error C1189: #error : ERROR: Use of C runtime library internal header file. 1>Generating Code... 1>Build log was saved at "file://g:\Qt\winceapp\Windows Mobile 6 Professional SDK (ARMV4I)\Release\BuildLog.htm" 1>WinCEApp - 3 error(s), 3 warning(s) ========== Rebuild All: 0 succeeded, 1 failed, 0 skipped ==========To copy to clipboard, switch view to plain text mode
The Qt->Change project's Qt Version doesn't seem to do anything (and yes, I have added both versions to the list, and they are classified correctly). What I'm confused about is how Qt or nmake knows the project should be compiled for WINCE. Is there some entry that can be changed in the pro file?
So yeah... I'm kind of stumped. If anyone could help, that'd be great.
~codeslicer
Bookmarks