Namespaces

Variants
Actions

Please note that as of October 24, 2014, the Nokia Developer Wiki will no longer be accepting user contributions, including new entries, edits and comments, as we begin transitioning to our new home, in the Windows Phone Development Wiki. We plan to move over the majority of the existing entries over the next few weeks. Thanks for all your past and future contributions.

(Difference between revisions)

Archived:Setting up environment for Qt Mobility API

From Wiki
Jump to: navigation, search
kiran10182 (Talk | contribs)
(Related articles)
hamishwillee (Talk | contribs)
 
(23 intermediate revisions by 7 users not shown)
Line 1: Line 1:
[[Category:Draft]][[Category:Qt for Symbian]]
+
{{Archived|The Qt Mobility APIs are now present in the [[Qt SDK]], which is the only SDK available for mobile development.}}
{{UnderConstruction}}
+
{{ArticleMetaData <!-- v1.2 -->
 +
|sourcecode= <!-- Link to example source code e.g. [[Media:The Code Example ZIP.zip]] -->
 +
|installfile= <!-- Link to installation file (e.g. [[Media:The Installation File.sis]]) -->
 +
|devices= <!-- Devices tested against - e.g. ''devices=Nokia 6131 NFC, Nokia C7-00'') -->
 +
|sdk= <!-- SDK(s) built and tested against (e.g. [http://linktosdkdownload/ Qt SDK 1.1.4]) -->
 +
|platform= <!-- Compatible platforms - e.g. Symbian^1 and later, Qt 4.6 and later -->
 +
|devicecompatability= <!-- Compatible devices e.g.: All* (must have internal GPS) -->
 +
|dependencies= <!-- Any other/external dependencies e.g.: Google Maps Api v1.0 -->
 +
|signing= <!-- Signing requirements - empty or one of: Self-Signed, DevCert, Manufacturer -->
 +
|capabilities= <!-- Capabilities required by the article/code example (e.g. Location, NetworkServices. -->
 +
|keywords= <!-- APIs, classes and methods (e.g. QSystemScreenSaver, QList, CBase -->
 +
|language= <!-- Language category code for non-English topics - e.g. Lang-Chinese -->
 +
|translated-by= <!-- [[User:XXXX]] -->
 +
|translated-from-title= <!-- Title only -->
 +
|translated-from-id= <!-- Id of translated revision -->
 +
|review-by= <!-- After re-review: [[User:username]] -->
 +
|review-timestamp= <!-- After re-review: YYYYMMDD -->
 +
|update-by= <!-- After significant update: [[User:username]]-->
 +
|update-timestamp= <!-- After significant update: YYYYMMDD -->
 +
|creationdate= 20100308
 +
|author= [[User:Kiran10182]]
 +
}}
 +
[[Category:Qt Mobility]][[Category:Symbian C++]]
 +
__TOC__
 +
This article explains how to set up a Symbian SDK to work with Qt Mobility APIs (this is no longer necessary because the APIs are included in the [[Qt SDK]]).
 +
{{Abstract|Deprecated)}}
  
== Overview ==
+
= Prerequisites =
This article covers how to set up environment to work with Qt Mobility API.
+
* Install the S60 SDK: [http://www.developer.nokia.com/info/sw.nokia.com/id/ec866fab-4b76-49f6-b5a5-af0631419e9c/S60_All_in_One_SDKs.html S60 Platform and Device SDKs for Symbian OS]. (In this article, S60 5th Edition SDK is used)
 +
* Use Carbide.c++ or Qt Creator as an IDE ((In this article, Carbide.c++ v2.4 is used).
 +
** To set up Carbide.c++, first install [http://www.developer.nokia.com/Resources/Tools_and_downloads/Other/Carbide.c++/ Carbide.c++ v2.3].
 +
** Upgrade it to latest version as shown in [http://www.developer.nokia.com/Community/Blogs/blog/lucian-tomutas-forum-nokia-blog/2010/02/01/upgrade-to-carbide.c-2.4 this blog post].
  
 +
= Steps =
  
 +
== Setup Qt ==
 +
* Download [http://qt.nokia.com/products/platform/symbian/ Qt].
  
== Prerequisite ==
+
* Install it on your PC.
* Install the S60 SDK.  
+
[[File:Qt4.6.2.PNG]]<br>
* In this series, S60 5th Edition SDK is used as a base. Download it from here: [http://www.forum.nokia.com/info/sw.nokia.com/id/ec866fab-4b76-49f6-b5a5-af0631419e9c/S60_All_in_One_SDKs.html S60 Platform and Device SDKs for Symbian OS]
+
* Use Carbide.c++ v2.3 or Qt Creator as an IDE
+
* In this series, Carbide.c++ v2.3 is used.
+
* Install Carbide.c++ v2.3. Download it from here: [http://www.forum.nokia.com/Tools_Docs_and_Code/Tools/IDEs/Carbide.c++/ Carbide.c++ v2.3]
+
  
== Steps ==
+
* Choose the path of installation
 +
[[File:Qt4.6.2 choose path.PNG]]<br>
  
=== Setup Qt 4.6.2 ===
 
* Download Qt 4.6.2 for Symbian from here: [http://qt.nokia.com/downloads/symbian-cpp qt-symbian-opensource-4.6.2.exe]
 
* Install it on your PC.
 
[[File:Qt4.6.2.PNG]]
 
  
* Choose the path of installation
+
* Choose the Symbian SDK(s)
[[File:Qt4.6.2_choose_path.PNG]]
+
[[File:Qt4.6.2 choose SDK.PNG]]<br>
  
* Choose the Symbian SDK
 
[[File:Qt4.6.2_choose_SDK.PNG]]
 
  
* Qt 4.6.2 provides its own configured command prompt with the variables set
+
* Qt provides a command prompt configured with the correct paths and environment variables for building Qt applications from the command line:
* Once the installation of Qt 4.6.2 is completed, you can find the Qt command prompt as shown in the following picture:
+
[[File:Qt4.6.2 command prompt.PNG]]<br>
[[File:Qt4.6.2_command_prompt.PNG]]
+
* Use this command prompt to work with Qt development which will make the process easier
+
{{Note|Current set of S60 devices do not have pre-installed Qt libraries on device. Please do not forget to install Qt libraries on the device before testing it on real device. You will find '''''qt_installer.sis''''' under '''C:\Qt\4.6.2''' folder. It contains all the dependency files in a single .sis file.}}
+
  
=== Setup Qt Mobility API 1.0.0 beta 1 ===
 
* After successful installation of Qt 4.6.2, the next step is to build Qt Mobility APIs
 
* Download QtMobility API: [http://qt.nokia.com/developer/new-qt-apis new-qt-apis]
 
* Extract it to the folder of your wish. In this series, it is extracted to '''C:\QtMobility\''' folder (Make sure to all the files directly under C:\QtMobility API to make the efforts easier)
 
* Once you have extracted the Qt Mobility API, perform the following steps:
 
* configure
 
[[File:Qt4.6.2_command_prompt_2.PNG]]
 
* make debug-winscw
 
[[File:Qt4.6.2_command_prompt_3.PNG]]
 
* make release-gcce
 
[[File:Qt4.6.2_command_prompt_4.PNG]]
 
  
* Download .sis  for your Symbian device from this link: http://get.qt.nokia.com/qt/solutions/qt-mobility-symbian-1.0.0-beta1.zip
+
{{Note|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.}}
* Extract that .zip file and you will find '''''install_to_device''''' folder in it.
+
* Install the '''''qt-mobility-1.0.0-beta1.sis''''' from '''''install_to_device''''' on your mobile phone.
+
  
 +
== Setup Qt Mobility API ==
 +
* After successful installation of Qt, the next step is to set up Qt Mobility
 +
* Download [http://qt.nokia.com/developer/qt-roadmap QtMobility API] (also known as ''New Qt APIs'') source and binary package for Symbian.
 +
* '''Edited by Rahul''' - I downloaded from here [http://qt.nokia.com/products/qt-addons QTMobilitySymbian API] above link was not having zip files required in next steps.
 +
* Extract the file to a suitable location. Here, {{Icode|C:\Qt}} is used.
 +
* Inside the package, you'll find the following files:
  
 +
** {{Icode|qt-mobility-1.0.0-epoc32-3.1.zip}}
 +
** {{Icode|qt-mobility-1.0.0-epoc32-3.2.zip}}
 +
** {{Icode|qt-mobility-1.0.0-epoc32-5.0.zip}}
 +
** {{Icode|convenienceheaders.zip}}
 +
** {{Icode|qtmobility.sis}}<br>
  
== Related articles ==  
+
* Extract {{Icode|qt-mobility-1.0.0-epoc32-<nowiki><S60 SDK></nowiki>.zip}} packages into the root folder of the respective S60 SDK.
 +
 
 +
** For example, if using S60 5th Edition SDK, extract {{Icode|qt-mobility-1.0.0-epoc32-5.0.zip}} into {{Icode|C:\S60\devices\S60_5th_Edition_SDK_v1.0}}. Repeat this step for all the Symbian SDKs you selected during Qt installation.
 +
 
 +
 
 +
* Extract {{Icode|convenienceheaders.zip}} into the root folder of each S60 SDK (as above).
 +
** This will enable Qt style include statements (e.g. {{Icode|#include <QSystemInfo>}} instead of {{Icode|#include <qsysteminfo.h>}}).
 +
 
 +
 
 +
* Install {{Icode|qtmobility.sis}} file to device. You can do this, for example, via bluetooth or using Nokia [[PC Suite]] (recommended).
 +
** Supported devices: S60 3rd Edition, Feature Pack 1 or later. see http://www.developer.nokia.com/Devices/ for device-specific information.
 +
 
 +
 
 +
* Copy (and rename) {{Icode|C:/Qt/qt-mobility-symbian-opensource-1.0.0/features/mobility.prf.template}} file to {{Icode|<nowiki><QTDIR></nowiki>/mkspecs/features/mobility.prf}}
 +
** <QTDIR> can be obtained by running 'qmake -v' from the Qt 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 command prompt:
 +
 
 +
<code>
 +
C:/Qt/qt-mobility-symbian-opensource-1.0.0> configure -examples
 +
</code><br>
 +
 
 +
 
 +
If configure completes successfully, build the examples:
 +
 
 +
<code>
 +
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
 +
</code><br>
 +
 
 +
 
 +
To generate a sis package and automatically deploy it to a device connected to [[PC Suite]],  use {{Icode|createpackage}} command with {{Icode|-i}} option. For example:
 +
 
 +
<code>
 +
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
 +
</code><br>
 +
 
 +
 
 +
{{Note|Using {{Icode|createpackage}} without ''certificate'' option will sign the application with a self-signed certificate. Only those examples that use basic capabilities ({{Icode|[http://library.developer.nokia.com/topic/Qt_for_Symbian_Developers_Library/GUID-5D7478BB-FFC0-48D3-ABB6-76E12F6AC3D5.html TARGET.CAPABILITY]}} in .pro file), granted by the user during installation, can be self-signed. See [[Capabilities]] for more information. }}<br>
 +
 
 +
= Related articles =  
 
* [[Getting started with Qt Mobility APIs]]
 
* [[Getting started with Qt Mobility APIs]]
 +
* [[Working with Carbide.c++ IDE for Qt Mobility APIs]]
 
* [[Working with QSystemInfo - System Information API - Part 1]]
 
* [[Working with QSystemInfo - System Information API - Part 1]]
 
* [[Working with QSystemInfo - System Information API - Part 2]]
 
* [[Working with QSystemInfo - System Information API - Part 2]]
Line 58: Line 123:
 
* [[Working with QSystemStorageInfo - System Information API]]
 
* [[Working with QSystemStorageInfo - System Information API]]
 
* [[Working with QSystemDisplayInfo - System Information API]]
 
* [[Working with QSystemDisplayInfo - System Information API]]
 +
* [[Working with QSystemNetworkInfo - System Information API - Part 1]]
 +
* [[Working with QSystemNetworkInfo - System Information API - Part 2]]
  
== Reference links==
+
= Reference links=
 
* [http://qt.nokia.com/ Qt - cross-platform application and UI framework]
 
* [http://qt.nokia.com/ Qt - cross-platform application and UI framework]
 
* [http://labs.trolltech.com/page/Projects/QtMobility Qt Mobility API]
 
* [http://labs.trolltech.com/page/Projects/QtMobility Qt Mobility API]
* [http://qt.nokia.com/developer/new-qt-apis New Qt APIs Beta - Mobility Project]
+
* [http://qt.nokia.com/developer/qt-roadmap New Qt APIs Beta - Mobility Project]
* SDK help
+
* SDK help[[Category:MeeGo Harmattan]] [[Category:Symbian]]
 
+
* more to come...
+

Latest revision as of 05:15, 21 June 2012

Archived.pngArchived: This article is archived because it is not considered relevant for third-party developers creating commercial solutions today. If you think this article is still relevant, let us know by adding the template {{ReviewForRemovalFromArchive|user=~~~~|write your reason here}}.

The Qt Mobility APIs are now present in the Qt SDK, which is the only SDK available for mobile development.

Article Metadata
Compatibility
Platform(s):
Symbian
Article
Created: kiran10182 (08 Mar 2010)
Last edited: hamishwillee (21 Jun 2012)

Contents

This article explains how to set up a Symbian SDK to work with Qt Mobility APIs (this is no longer necessary because the APIs are included in the Qt SDK). Deprecated)

[edit] Prerequisites

[edit] Steps

[edit] Setup Qt

  • Download Qt.
  • 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 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.

[edit] Setup Qt Mobility API

  • After successful installation of Qt, 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 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 command prompt.


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

[edit] Building the examples

To test that you have a working environment, try building the examples from Qt 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.


[edit] Related articles

[edit] Reference links

This page was last modified on 21 June 2012, at 05:15.
163 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.

×