Qt Build for WinCe 6.0 fails with Link errors
Hi ,I was trying to build Qt for Wince (PocketPc SDK). But there were some errors. Please help me to resolve these issues 1) Configuration : configure -platform win32-msvc2005 -xplatform wincewm50pocket-msvc2005 ####Nmake paths#### set INCLUDE=d:\Program Files\Microsoft Visual Studio 8\VC\ce\include;D:\Program Files\Microsoft Visual Studio 8\SmartDevices\SDK\PocketPC2003\Include
set LIB=d:\Program Files\Microsoft Visual Studio 8\VC\ce\lib\armv4;D:\Program Files\Microsoft Visual Studio 8\SmartDevices\SDK\PocketPC2003\Lib\armv4
set PATH=d:\Program Files\Microsoft Visual Studio 8\VC\ce\bin\x86_arm;PATH2) Error – Link error. After compilation it throws this error moc_qeventtransition.cpp Generating Code… link /LIBPATH:“d:\Qt\4.7\lib” /LIBPATH:“d:\Qt\4.7\lib” /NOLOGO /NODEFAULTLIB:OLDNAMES.LIB /DEBUG /SUBSYSTEM:WINDOWSCE,5.01 /MACHINE:THUMB /DLL /VERSION:4.73 /OUT:..\..\lib\QtCored4.dll
- Creating library ..\..\lib\QtCored4.lib and object ..\..\lib\QtCored4.exp
- QtCored_pch.obj : error LNK2001: unresolved external symbol "const type_info::`vftable'" (??_7type_info@@6B
My Build last time i did had substantially longer paths including some out of our WinCE project ill post them below incase they are of any use to you. PCB06998_ARMV4I will be probably different in your case.
configure -platform win32-msvc2005 -xplatform wince60standard-armv4i-msvc2005 -rtti -exceptions -stl -qt-gif -multimedia -audio-backend
- C:/Program Files/Microsoft Visual Studio 8/VC/ce/include;
- C:/Program Files/Microsoft Visual Studio 8/VC/ce/atlmfc/include;
- C:/Program Files/Microsoft Visual Studio 8/SmartDevices/SDK/SQL Server/Mobile/v3.0;
- C:/Program Files/Microsoft Visual Studio 8/VC/ce/lib/armv4i;
- C:/Program Files/Microsoft Visual Studio 8/VC/ce/atlmfc/lib/armv4i;
- C:\Program Files\Microsoft Visual Studio 8\VC\ce\lib\armv4i;
- C:/Program Files/Microsoft Visual Studio 8/VC/ce/bin/x86_arm;
- C:/Program Files/Microsoft Visual Studio 8/VC/ce/bin/x86_cex86;
- C:/Program Files/Microsoft Visual Studio 8/VC/bin;
- C:/Program Files/Microsoft Visual Studio 8/VC/PlatformSDK/bin;
- C:/Program Files/Microsoft Visual Studio 8/Common7/Tools;
- C:/Program Files/Microsoft Visual Studio 8/Common7/IDE;
- C:/Program Files/Microsoft Visual Studio 8/
Did you build this from a source distribution, or from a binary distribution? Building from binary distributions usually create problems, so I would strongly recommend building from a source distribution.
Also, I would suggest using the setcepaths script instead of setting the variables yourself.
(I assume you’ve used the information on this page [doc.qt.nokia.com], which also tells you that you can use setcepaths instead of setting them yourself.)
I have successfully built Qt for Windows Mobile 6 several times, but I have always done it using shadow builds (see this page [doc.qt.nokia.com] for more info). Note that you may have to omit the examples when doing a shadow build (-nomake examples).
hello,Thanks for your inputs. I tried to build shadow build. Again it fails in linking stage. I used setcepaths, but it failed in compilation itself saying “WinMain cannot not be overloaded”. So I manually set the paths and was trying to build. 1) I have PocketPC 2003 SDK installed on WinXp 2) WinCe Platform Builder is also installed on my pc. 3) I dont find Arm4i folder under my PocketPC SDK folder. There is only Arm4 folder.(SDK\PocketPC\lib\Arm4,SDK\PocketPC\Include\Arm4) I doubt the path and some libraries missing in my WinCe 6.0 platform builder installation. Please help me to resolve the issue.
The -xplatform wincewm50pocket-msvc2005 configure option is for the “standard” Windows Mobile 5 SDK (based on Windows CE 5.0).
PocketPC 2003 is based on Windows CE 4.2
Do you really have to use the PocketPC 2003 SDK ?
If I remember correctly, Qt does not support officially supports pre-WM5.0 versions of Windows Mobile.
If you want to try to add support for PocketPC 2003 you will have to add a custom folder in the mkspec subfolder of the Qt sources (i.e. pocketpc2003-msvc2005) and put there custom configuration files derived from the WM50 ones.
Then as configure option you have to use -xplatform pocketpc2003-msvc2005 to select your custom build options and instead of using setcepaths you will have to manually set PATH, INCLUDE and LIB environment variables to point at msvc2005 for ARM and to the pocketpc2003 sdk include and lib folders.
For example to set envirnment variables for msvc2005 and colibri600 sdk (a custom SDK for Windows CE 6.0) I did the following:
set INCLUDE=C:\Program Files (x86)\Microsoft Visual Studio 8\VC\ce\include;C:\Program Files (x86)\Microsoft Visual Studio 8\VC\ce\atlmfc\include;C:\Program Files (x86)\Windows CE Tools\wce600\Colibri600\Include\Armv4i
set LIB=C:\Program Files (x86)\Microsoft Visual Studio 8\VC\ce\lib\armv4i;C:\Program Files (x86)\Microsoft Visual Studio 8\VC\ce\atlmfc\lib\armv4i;C:\Program Files (x86)\Windows CE Tools\wce600\Colibri600\Lib\ARMV4I
set LIBPATH=C:\Program Files (x86)\Microsoft Visual Studio 8\VC\ce\lib\armv4i;C:\Program Files (x86)\Microsoft Visual Studio 8\VC\ce\atlmfc\lib\armv4i;C:\Program Files (x86)\Windows CE Tools\wce600\Colibri600\Lib\ARMV4I
set PATH=C:\Program Files (x86)\Microsoft Visual Studio 8\VC\ce\bin\x86_arm;PATH
Later following another discussion in this forum I discovered I could do the same with:
checksdk.exe -sdk “Colibri600 (ARMV4I)” -script tmp_created_script_setup.bat
But I dont know if checksdk.exe works with pre-Windows CE 5.0 SDKs.
I forgot to add these links to previous discussions that may be useful:
(building with custom SDKs etc. etc.)
(where tiger86 found it si possible to use checksdk for custom sdks)
Krrish i never got set paths to work ether. I also had more build errors then link ones and spent a large amount of time using windows search to locate the required header files. Luckly for me the company i work for has since migrated to embedded linux so i don’t have to deal with these issues anymore
@Krrish: Ditto for what SimonL said, I never got them working, but it’s not too hard to just create your own batch file to set them. The paths won’t change once you’ve got it to work so just version it and then it’s job done.
Another thing I’ve found is that using a shadow build is a must because the “clean” of a configuration rarely works (for me) so I just delete the shadow directory and start again.
Could you post the configure line your using (for the shadow build) as this might help?