×
Namespaces

Variants
Actions
(Difference between revisions)

Archived:Setting up environment for Qt Mobility API

From Nokia Developer Wiki
Jump to: navigation, search
divanov (Talk | contribs)
hamishwillee (Talk | contribs)
m (Add more visible disclaimer that this is not needed for most developers)
Line 1: Line 1:
[[Category:Qt]][[Category:Qt for Symbian]][[Category:Qt Mobility]][[Category:Symbian C++]]
+
[[Category:Qt]][[Category:Qt Mobility]][[Category:Symbian]][[Category:Symbian C++]]
= Overview =
+
{{Abstract|visible=true|This article explains how to set up a Symbian SDK to work with Qt Mobility APIs. This is not necessary if you're using the [[Nokia Qt SDK]].}}
This article covers how to set up S60 SDK to work with Qt Mobility API. '''If you are using Qt SDK (or former Nokia Qt SDK), then Qt Mobility is part of it and already configured, so no additional installation or configuration is required.'''
+
 
 +
{{Tip|Use the [[Nokia Qt SDK]] instead of these instructions unless you specifically need to call Symbian C++ APIs that are not present in the [http://doc.qt.nokia.com/qtmobility-1.0/index.html Qt Mobility APIs]}}
  
 
= Prerequisites =
 
= Prerequisites =

Revision as of 04:22, 5 April 2011

This article explains how to set up a Symbian SDK to work with Qt Mobility APIs. This is not necessary if you're using the Nokia Qt SDK.

Tip.pngTip: Use the Nokia Qt SDK instead of these instructions unless you specifically need to call Symbian C++ APIs that are not present in the Qt Mobility APIs

Contents

Prerequisites

Steps

Setup Qt for Symbian

  • Install it on your PC.

Qt4.6.2.PNG

  • Choose the path of installation

Qt4.6.2 choose path.PNG


  • Choose the Symbian SDK(s)

Qt4.6.2 choose SDK.PNG


  • Qt for Symbian provides a command prompt configured with the correct paths and environment variables for building Qt applications from the command line:

Qt4.6.2 command prompt.PNG


Note.pngNote: Before testing a Qt application on a (S60 3rd Edition or 5th Edition) phone, Qt libraries must be installed on the device. Easiest way to do this is to connect the device to the PC using Nokia PC Suite and use the qt_installer.sis, located in the root folder of Qt installation. This .sis file will install all Qt libraries and dependencies to an S60 device.


Setup Qt Mobility API

  • After successful installation of Qt for Symbian, the next step is to set up Qt Mobility
  • Download QtMobility API (also known as New Qt APIs) source and binary package for Symbian.
  • Edited by Rahul - I downloaded from here QTMobilitySymbian API above link was not having zip files required in next steps.
  • Extract the file to a suitable location. Here, C:\Qt is used.
  • Inside the package, you'll find the following files:
    • qt-mobility-1.0.0-epoc32-3.1.zip
    • qt-mobility-1.0.0-epoc32-3.2.zip
    • qt-mobility-1.0.0-epoc32-5.0.zip
    • convenienceheaders.zip
    • qtmobility.sis
  • Extract qt-mobility-1.0.0-epoc32-<S60 SDK>.zip packages into the root folder of the respective S60 SDK.
    • For example, if using S60 5th Edition SDK, extract qt-mobility-1.0.0-epoc32-5.0.zip into C:\S60\devices\S60_5th_Edition_SDK_v1.0. Repeat this step for all the Symbian SDKs you selected during Qt for Symbian installation.


  • Extract convenienceheaders.zip into the root folder of each S60 SDK (as above).
    • This will enable Qt style include statements (e.g. #include <QSystemInfo> instead of #include <qsysteminfo.h>).


  • Install qtmobility.sis file to device. You can do this, for example, via bluetooth or using Nokia PC Suite (recommended).


  • Copy (and rename) C:/Qt/qt-mobility-symbian-opensource-1.0.0/features/mobility.prf.template file to <QTDIR>/mkspecs/features/mobility.prf
    • <QTDIR> can be obtained by running 'qmake -v' from the Qt for Symbian command prompt.


You now have a working environment for building Qt projects that use QtMobility libraries.

Building the examples

To test that you have a working environment, try building the examples from Qt for Symbian command prompt:

C:/Qt/qt-mobility-symbian-opensource-1.0.0> configure -examples


If configure completes successfully, build the examples:

C:/Qt/qt-mobility-symbian-opensource-1.0.0> cd examples
C:/Qt/qt-mobility-symbian-opensource-1.0.0/examples> qmake
C:/Qt/qt-mobility-symbian-opensource-1.0.0/examples> make release-gcce


To generate a sis package and automatically deploy it to a device connected to PC Suite, use createpackage command with -i option. For example:

C:/Qt/qt-mobility-symbian-opensource-1.0.0/examples> cd bearercloud
C:/Qt/qt-mobility-symbian-opensource-1.0.0/examples/bearercloud> createpackage -i bearercloud_template.pkg release-gcce


Note.pngNote: Using createpackage without certificate option will sign the application with a self-signed certificate. Only those examples that use basic capabilities (TARGET.CAPABILITY in .pro file), granted by the user during installation, can be self-signed. See Capabilities for more information.


Related articles

Reference links

244 page views in the last 30 days.

Was this page helpful?

Your feedback about this content is important. Let us know what you think.

 

Thank you!

We appreciate your feedback.

×