PDA

View Full Version : Qt Mobility Examples not working



leloo
13th June 2011, 05:21
Hello all,

First of all, I apologize now for any spelling or grammar mistakes, as English is not my native language. :)

Could someone please give me an example/explanation/tutorial/advise/idea on how to run the Qt Mobility examples? I have found tutorials on what every code line does, but not how to run it.

I am a newbie in Qt, so what could be more helpful than studying the examples? This is what happens:

I open the example from the welcoming tab => Qt Mobility => Maps Demo ( that is the example I am interested in, but none of the Mobility examples are working )

I run the application and I get 110 errors.. ( some of the errors are at the end of this post )

The header files qgaphicsgeomap.h, qgeocoordinate.h and all others from below are not found in the project directory. Of course they are not in the C:\QtSDK\Examples\4.7\mobile\mapsdemo

Do I need to install something extra? The latest Qt SDK from the nokia site is Qt SDK 1.1 and it includes the Qt Mobility API ( http://labs.qt.nokia.com/2011/05/04/qt-sdk-1-1-released ), so normaly the examples should work. Is it something wrong with the instalation?

Can someone please give me an idea on what I am doing wrong? Any help would be appreciated.

By the way, I have not posted the code, as I have not changed anything in the example.



Running build steps for project mapsdemo...
Configuration unchanged, skipping qmake step.
Starting: "C:\QtSDK\mingw\bin\mingw32-make.exe"
C:/QtSDK/mingw/bin/mingw32-make -f Makefile.Debug
mingw32-make[1]: Entering directory `C:/QtSDK/Examples/4.7/mobile/mapsdemo-build-desktop'
g++ -c -g -frtti -fexceptions -mthreads -Wall -DUNICODE -DQT_LARGEFILE_SUPPORT -DQT_DLL -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -DQT_HAVE_MMX -DQT_HAVE_3DNOW -DQT_HAVE_SSE -DQT_HAVE_MMXEXT -DQT_HAVE_SSE2 -DQT_THREAD_SUPPORT -DQT_NEEDS_QMAIN -I"..\..\..\..\Desktop\Qt\4.7.3\mingw\include\QtCore" -I"..\..\..\..\Desktop\Qt\4.7.3\mingw\include\QtNetwo rk" -I"..\..\..\..\Desktop\Qt\4.7.3\mingw\include\QtGui" -I"..\..\..\..\Desktop\Qt\4.7.3\mingw\include" -I"..\..\..\..\Desktop\Qt\4.7.3\mingw\include\ActiveQ t" -I"debug" -I"..\mapsdemo" -I"." -I"..\..\..\..\Desktop\Qt\4.7.3\mingw\mkspecs\win32-g++" -o debug\mapswidget.o ..\mapsdemo\mapswidget.cpp
In file included from ..\mapsdemo\mapswidget.cpp:42:
..\mapsdemo\/mapswidget.h:51:29: error: qgraphicsgeomap.h: No such file or directory
..\mapsdemo\/mapswidget.h:52:32: error: qgeomappingmanager.h: No such file or directory
..\mapsdemo\/mapswidget.h:53:28: error: qgeocoordinate.h: No such file or directory
In file included from ..\mapsdemo\mapswidget.cpp:43:
..\mapsdemo\/marker.h:47:33: error: qgeomappixmapobject.h: No such file or directory
..\mapsdemo\/marker.h:48:31: error: qgeosearchmanager.h: No such file or directory
..\mapsdemo\/marker.h:51:25: error: qgeoaddress.h: No such file or directory
..\mapsdemo\/marker.h:52:29: error: qgeosearchreply.h: No such file or directory
In file included from ..\mapsdemo\mapswidget.cpp:42:
..\mapsdemo\/mapswidget.h:55: error: 'QtMobility' is not a namespace-name
..\mapsdemo\/mapswidget.h:55: error: expected namespace-name before ';' token
..\mapsdemo\/mapswidget.h:65: error: expected class-name before '{' token
..\mapsdemo\/mapswidget.h:72: error: expected ')' before '*' token
..\mapsdemo\/mapswidget.h:85: error: ISO C++ forbids declaration of 'QGeoMapObject' with no type
..\mapsdemo\/mapswidget.h:85: error: expected ';' before '*' token
..\mapsdemo\/mapswidget.h:123: error: ISO C++ forbids declaration of 'QGraphicsGeoMap' with no type
..\mapsdemo\/mapswidget.h:123: error: expected ';' before '*' token
..\mapsdemo\/mapswidget.h:126: error: 'QGeoCoordinate' has not been declared
..\mapsdemo\/mapswidget.h:127: error: 'QGeoCoordinate' has not been declared
..\mapsdemo\/mapswidget.h:130: error: 'QGeoMappingManager' has not been declared
In file included from ..\mapsdemo\mapswidget.cpp:43:
..\mapsdemo\/marker.h:54: error: 'QtMobility' is not a namespace-name
.
.
.
.

Aman607
15th June 2011, 23:49
Im also new to qt but the way to run example is simple
start a new project and copy paste all the files in example n run the example