Using Mobility 1.1 APIs on Windows
-
I am trying to use the latest mobility APIs under Qt Creator under Windows. When I build them via the Visual Studio command prompt I get...
cd src\ && "C:\Program Files\Microsoft Visual Studio 8\VC\BIN\nmake.exe" -f Makefile
cd global\ && "C:\Program Files\Microsoft Visual Studio 8\VC\BIN\nmake.exe" -f Makefile
cd mobilitysimulator\ && "C:\Program Files\Microsoft Visual Studio 8\VC\BIN\nmake.exe" -f Makefile
"C:\Program Files\Microsoft Visual Studio 8\VC\BIN\nmake.exe" -f Makefile.Debug all
cl -c -nologo -Zm200 -Zc:wchar_t- -Zi -MDd -GR -EHsc -W3 -w34100 -w34189 -DUNICODE -DWIN32 -DQT_LARGEFILE_SUPPORT -DQT_SHARED -DQTM_PLUGIN_PATH="C:/QtMobility/plugins" -DQT_BUILD_MOBILITYSIMULATOR_LIB -DQT_MAKEDLL -DQT_DLL -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -DQT_THREAD_SUPPORT -I"c:\NokiaQtSDK\Simulator\Qt\msvc2005\include\QtCore" -I"c:\NokiaQtSDK\Simulator\Qt\msvc2005\include\QtNetwork" -I"c:\NokiaQtSDK\Simulator\Qt\msvc2005\include\QtGui" -I"c:\NokiaQtSDK\Simulator\Qt\msvc2005\include" -I"." -I"..\global" -I"c:\NokiaQtSDK\Simulator\Qt\msvc2005\include\ActiveQt" -I"....\build\Debug\QtMobilitySimulator\moc" -I"c:\NokiaQtSDK\Simulator\Qt\msvc2005\mkspecs\default" -Fo....\build\Debug\QtMobilitySimulator\ @C:\DOCUME~1\Judge\LOCALS~1\Temp\nmFC.tmp
mobilityconnection.cpp
c:\qt-mobility-opensource-src-1.1.0\src\mobilitysimulator\mobilityconnection_p.h(50) : fatal error C1083: Cannot open include file: 'private/qsimulatordata_p.h': No such file or directoryI also wonder why I have to build the APIs. Why can't these be provided ready built? Why can't they be automatically included (and upgraded) via Qt Creator?
Thanks
Simon
-
I have the exact same error while trying to compile qt mobility... fatal error C1083: Cannot open include file: 'private/qsimulatordata_p.h': No such file or directory
I also have the same complaint about the Qt SDKs: there are a gazillion of SDKs: on for Desktop development. I said 1? Not actually at least 3: mingw stuff, visual studio 2005, 2008 etc. Now to develop for mobile you have to install a separate Nokia QT SDK . If you want to use mobility you have to download AND compile separate mobility stuff. WHY is not only 1 SDK for both desktop & mobile? Most of the functionality in mobility should also be available in desktop too, like bluetooth or camera or even GPS for newer netbooks/laptops that come with integrated GPS. Anyway I must compile a big project in QT: all these different targets almost compile (like 90%) but none 100%. For example for mingw (desktop or mobile SDK one might ask :D?) I have compilation errors about operators new/delete not being defined. For Symbian target I get compilation/linking errors about the same operators having multiple definitions and for maemo (or meego?!?) target I have one header file in my project that happens to have the same name as a platform header, and the compiler includes the platform header so the compilation fails. Instead of trying to offer so much choices (mingw, vs2005, vs2008, vs2010 etc) why not pick one and make sure that single one is supported and works 100%
Also: I have QT sdk (for desktop) installed, which installed QtCreator. Nokia QT SDK (for mobile) also comes with QtCreator. Can I use QtCreator from the desktop SDK to build mobile projects? I ask because they look the same, and I can not make them apart. Is there a difference?
Also: what's with the different version naming: some QT SDKs are named Qt 4.7.0 for example while others are named like 2010.05 (I think this is the desktop one). Now I should know that 2010.5 is actually using version 4.7.0 of QT, but that's only because when the QT 4.7.0 was announced I got to the download page and remembered that 2010.05 is related to 4.7.0 (I made a note on a napkin). There is no way to go like Help->About and tell me the classic version of QT for one of the gazillion possible QT SDKs
I am an idiot: I want one single .EXE setup file that installs everything and I do not have to compile myself anything, I just want to do NEXT NEXT NEXT FINISH
-
Last week Nokia released a tech preview of what you need. Try this...
http://www.forum.nokia.com/info/sw.nokia.com/id/da8df288-e615-443d-be5c-00c8a72435f8/Qt_SDK.htmlNo need to compile separate components.
Simon
-
I installed the Qt SDK 1.1 (Technology Preview) from the link Simon gave above;
Now I am trying to compile the lbs example from:
http://wiki.forum.nokia.com/index.php/Get_continuous_location_updates_using_Qt_Mobility_APII am using QtCreator to compile. I am getting the following compile errors:
Running build steps for project QTest...
Configuration unchanged, skipping qmake step.
Starting: "C:\qtsdk\maemo\4.6.2\bin\make.exe" -w
make: Entering directory/c/work/qt/QTest' g++ -c -pipe -O3 -fno-omit-frame-pointer -fno-optimize-sibling-calls -Wall -W -D_REENTRANT -DQT_GL_NO_SCISSOR_TEST -DQT_DEFAULT_TEXTURE_GLYPH_CACHE_WIDTH=1024 -DNETWORKACCESS -DQT_NO_DEBUG -DQT_GUI_LIB -DQT_CORE_LIB -DQT_SHARED -I../../../QtSDK/Maemo/4.6.2/sysroots/fremantle-arm-sysroot-20.2010.36-2-slim/usr/share/qt4/mkspecs/default -I. -I../../../QtSDK/Maemo/4.6.2/sysroots/fremantle-arm-sysroot-20.2010.36-2-slim/usr/include/QtCore -I../../../QtSDK/Maemo/4.6.2/sysroots/fremantle-arm-sysroot-20.2010.36-2-slim/usr/include/QtGui -I../../../QtSDK/Maemo/4.6.2/sysroots/fremantle-arm-sysroot-20.2010.36-2-slim/usr/include -I. -o LocationWatcher.o LocationWatcher.cpp make: Leaving directory
/c/work/qt/QTest'
In file included from LocationWatcher.cpp:3:
locationwatcher.h:5:34: error: QGeoPositionInfoSource: No such file or directory
In file included from LocationWatcher.cpp:3:
locationwatcher.h:7: error: 'QtMobility' is not a namespace-name
locationwatcher.h:7: error: expected namespace-name before ';' token
locationwatcher.h:19: error: expected ',' or '...' before '&' token
locationwatcher.h:19: error: ISO C++ forbids declaration of 'QGeoPositionInfo' with no type
locationwatcher.h:22: error: ISO C++ forbids declaration of 'QGeoPositionInfoSource' with no type
locationwatcher.h:22: error: expected ';' before '' token
LocationWatcher.cpp: In constructor 'LocationWatcher::LocationWatcher(QObject)':
LocationWatcher.cpp:8: error: 'source' was not declared in this scope
LocationWatcher.cpp:8: error: 'QGeoPositionInfoSource' has not been declared
LocationWatcher.cpp:12: error: 'QGeoPositionInfoSource' has not been declared
LocationWatcher.cpp: In member function 'void LocationWatcher::enable()':
LocationWatcher.cpp:18: error: 'source' was not declared in this scope
LocationWatcher.cpp: In member function 'void LocationWatcher::disable()':
LocationWatcher.cpp:28: error: 'source' was not declared in this scope
LocationWatcher.cpp: At global scope:
LocationWatcher.cpp:36: error: expected ',' or '...' before '&' token
LocationWatcher.cpp:36: error: ISO C++ forbids declaration of 'QGeoPositionInfo' with no type
LocationWatcher.cpp: In member function 'void LocationWatcher::positionUpdated(int)':
LocationWatcher.cpp:38: error: 'info' was not declared in this scope
LocationWatcher.cpp: At global scope:
LocationWatcher.cpp:36: warning: unused parameter 'QGeoPositionInfo'
make: *** [LocationWatcher.o] Error 1
The process "C:\qtsdk\maemo\4.6.2\bin\make.exe" exited with code 2.
Error while building project QTest (target: Maemo)
When executing build step 'Make'So it seems the compiler can not find the QGeoPositionInfoSource header file and also does not recognize the namespace QtMobility.
I have searched on my installation directory of the Qt SDK 1.1 for QGeoPositionInfoSource files and it finds them in the following locations:
C:\QtSDK\Maemo\4.6.2\sysroots\fremantle-arm-sysroot-20.2010.36-2-slim\usr\include\QtLocation\qgeopositioninfosource.h
C:\QtSDK\Simulator\QtMobility\mingw\include\QtLocation\QGeoPositionInfoSource
C:\QtSDK\Simulator\QtMobility\mingw\include\QtLocation\qgeopositioninfosource.h
C:\QtSDK\Simulator\QtMobility\msvc2005\include\QtLocation\QGeoPositionInfoSource
C:\QtSDK\Simulator\QtMobility\msvc2005\include\QtLocation\qgeopositioninfosource.h
C:\QtSDK\Simulator\QtMobility\msvc2008\include\QtLocation\QGeoPositionInfoSource
C:\QtSDK\Simulator\QtMobility\msvc2008\include\QtLocation\qgeopositioninfosource.h
C:\QtSDK\Symbian\SDKs\Symbian1Qt471\epoc32\include\middleware\QGeoPositionInfoSource
C:\QtSDK\Symbian\SDKs\Symbian1Qt471\epoc32\include\middleware\qgeopositioninfosource.h
C:\QtSDK\Symbian\SDKs\Symbian1Qt471\src\location\qgeopositioninfosource.h
C:\QtSDK\Symbian\SDKs\Symbian1Qt471\src\location\qgeopositioninfosource_maemo5_p.h
C:\QtSDK\Symbian\SDKs\Symbian1Qt471\src\location\qgeopositioninfosource_maemo_p.h
C:\QtSDK\Symbian\SDKs\Symbian1Qt471\src\location\qgeopositioninfosource_s60_p.h
C:\QtSDK\Symbian\SDKs\Symbian1Qt471\src\location\qgeopositioninfosource_simulator_p.h
C:\QtSDK\Symbian\SDKs\Symbian1Qt471\src\location\qgeopositioninfosource_wince_p.h
C:\QtSDK\Symbian\SDKs\Symbian3Qt471\epoc32\include\mw\QGeoPositionInfoSource
C:\QtSDK\Symbian\SDKs\Symbian3Qt471\epoc32\include\mw\qgeopositioninfosource.h
C:\QtSDK\Symbian\SDKs\Symbian3Qt471\src\location\qgeopositioninfosource.h
C:\QtSDK\Symbian\SDKs\Symbian3Qt471\src\location\qgeopositioninfosource_maemo5_p.h
C:\QtSDK\Symbian\SDKs\Symbian3Qt471\src\location\qgeopositioninfosource_maemo_p.h
C:\QtSDK\Symbian\SDKs\Symbian3Qt471\src\location\qgeopositioninfosource_s60_p.h
C:\QtSDK\Symbian\SDKs\Symbian3Qt471\src\location\qgeopositioninfosource_simulator_p.h
C:\QtSDK\Symbian\SDKs\Symbian3Qt471\src\location\qgeopositioninfosource_wince_p.hSo it looks like QtMobilty was installed but QtCreator does not see it. I am using Windows 7 32 bit
Can someone help?
Thanks