×
Namespaces

Variants
Actions
(Difference between revisions)

Latest Qt and Qt mobility evaluation on Maemo

From Nokia Developer Wiki
Jump to: navigation, search
achipa (Talk | contribs)
hamishwillee (Talk | contribs)
m (Hamishwillee - Bot update - Add ArticleMetaData)
(5 intermediate revisions by 2 users not shown)
Line 1: Line 1:
 +
{{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= 20101231
 +
|author= [[User:Achipa]]
 +
}}
 
[[Category:Maemo]][[Category:Qt Mobility]]
 
[[Category:Maemo]][[Category:Qt Mobility]]
{{Abstract|This article explains how to get and install the latest ''evaluation'' versions of Qt and Qt Mobility for Maemo 5 from the Extras-devel repository.}}
+
{{Abstract|This article explains how to get and install the latest ''community supported'' versions of Qt and Qt Mobility for Maemo 5 from the Extras-devel repository.}}
  
Note that these libraries cannot be used for publishing software to Ovi nor do they come with any warranty, but are good for evaluating real-life performance and behavior. The components that are part of this initiative are labeled with '''experimental''' in their package names. They are installed in parallel to the Maemo5 libraries, so they pose minimal danger to your existing install and do not affect stable software written for Maemo.
+
Note that these libraries cannot be used for publishing software to Ovi nor do they come with any warranty, but are good for evaluating real-life performance and behavior. They are installed in parallel to the Maemo5 libraries, so they pose minimal danger to your existing install and do not affect stable software written for Maemo.
  
 
NOTE: All the packages referenced are found in extras-devel
 
NOTE: All the packages referenced are found in extras-devel
  
= Qt Mobility 1.1.3 =
+
= Qt Mobility 1.2 =
  
[http://maemo.org/packages/package_instance/view/fremantle_extras-devel_free_armel/libqtm-11-dev/1.1.2-0fn~fremantle0 libqtm-11-dev package]
+
[http://repository.maemo.org/extras-devel/pool/fremantle/free/q/qt-mobility/libqtm-12-dev_1.2.0+git20111104-0nd~fremantle5_armel.deb libqtm-12-dev package]
  
Both QtSDK and Scratchbox environments are supported and the 1.1 mobility packages are available from Extras. Use the one you're more familiar with.
+
Both QtSDK and Scratchbox environments are supported and the 1.2 mobility packages are available from Extras. Use the environment you're more familiar with.
  
 
=== QtSDK install ===
 
=== QtSDK install ===
  
Download the mobility packages from maemo.org ([http://repository.maemo.org/extras-devel/pool/fremantle/free/q/qt-mobility11/libqtm-11-bearer_1.1.2-0fn~fremantle0_armel.deb bearer (legacy)],
+
Download the mobility packages from maemo.org ([http://repository.maemo.org/extras-devel/pool/fremantle/free/q/qt-mobility/libqtm-12-dev_1.2.0+git20111104-0nd~fremantle5_armel.deb deb package here])
[http://repository.maemo.org/extras-devel/pool/fremantle/free/q/qt-mobility11/libqtm-11-contacts_1.1.2-0fn~fremantle0_armel.deb contacts],
+
[http://repository.maemo.org/extras-devel/pool/fremantle/free/q/qt-mobility11/libqtm-11-declarative_1.1.2-0fn~fremantle0_armel.deb declarative],
+
[http://repository.maemo.org/extras-devel/pool/fremantle/free/q/qt-mobility11/libqtm-11-dev_1.1.2-0fn~fremantle0_armel.deb Headers (-dev)],
+
[http://repository.maemo.org/extras-devel/pool/fremantle/free/q/qt-mobility11/libqtm-11-feedback_1.1.2-0fn~fremantle0_armel.deb feedback],
+
[http://repository.maemo.org/extras-devel/pool/fremantle/free/q/qt-mobility11/libqtm-11-gallery_1.1.2-0fn~fremantle0_armel.deb gallery],
+
[http://repository.maemo.org/extras-devel/pool/fremantle/free/q/qt-mobility11/libqtm-11-location_1.1.2-0fn~fremantle0_armel.deb location],
+
[http://repository.maemo.org/extras-devel/pool/fremantle/free/q/qt-mobility11/libqtm-11-messaging_1.1.2-0fn~fremantle0_armel.deb messaging],
+
[http://repository.maemo.org/extras-devel/pool/fremantle/free/q/qt-mobility11/libqtm-11-multimedia_1.1.2-0fn~fremantle0_armel.deb multimedia],
+
[http://repository.maemo.org/extras-devel/pool/fremantle/free/q/qt-mobility11/libqtm-11-organizer_1.1.2-0fn~fremantle0_armel.deb organizer],
+
[http://repository.maemo.org/extras-devel/pool/fremantle/free/q/qt-mobility11/libqtm-11-publishsubscribe_1.1.2-0fn~fremantle0_armel.deb publishsubscribe],
+
[http://repository.maemo.org/extras-devel/pool/fremantle/free/q/qt-mobility11/libqtm-11-sensors_1.1.2-0fn~fremantle0_armel.deb sensors],
+
[http://repository.maemo.org/extras-devel/pool/fremantle/free/q/qt-mobility11/libqtm-11-serviceframework_1.1.2-0fn~fremantle0_armel.deb serviceframework],
+
[http://repository.maemo.org/extras-devel/pool/fremantle/free/q/qt-mobility11/libqtm-11-systeminfo_1.1.2-0fn~fremantle0_armel.deb systeminfo],
+
[http://repository.maemo.org/extras-devel/pool/fremantle/free/q/qt-mobility11/libqtm-11-versit_1.1.2-0fn~fremantle0_armel.deb versit])
+
  
 
Open a shell prompt and go to the directory with the downloaded files and install them into your rootstrap with:
 
Open a shell prompt and go to the directory with the downloaded files and install them into your rootstrap with:
  
 
'''Linux'''
 
'''Linux'''
  /path/to/your/QtSDK/Maemo/4.6.2/bin/mad-admin xdpkg -i filename.deb
+
  /path/to/your/QtSDK/Maemo/4.6.2/bin/mad-admin xdpkg -i libqtm-12-dev_1.2.0+git20111104-0nd~fremantle5_armel.deb  
 
+
  /path/to/your/QtSDK/Maemo/4.6.2/bin/mad-admin xdpkg -i libqtm-12_1.2.0+git20111104-0nd~fremantle5_armel.deb
(or, if you are installing them all at once)
+
 
+
  for i in `ls libqtm*deb` ; do ~/QtSDK/Maemo/4.6.2/bin/mad-admin xdpkg -i $i ; done
+
  
 
'''Windows'''
 
'''Windows'''
  \path\to\your\QtSDK\Maemo\4.6.2\wbin\mad-admin.exe xdpkg -i filename.deb
+
  \path\to\your\QtSDK\Maemo\4.6.2\wbin\mad-admin.cmd xdpkg -i libqtm-12-dev_1.2.0+git20111104-0nd~fremantle5_armel.deb
 
+
  \path\to\your\QtSDK\Maemo\4.6.2\wbin\mad-admin.cmd xdpkg -i libqtm-12_1.2.0+git20111104-0nd~fremantle5_armel.deb
(or, if you are installing them all at once)
+
 
+
  for /f %%a IN ('dir /b *.deb') do call C:\QtSDK\Maemo\4.6.2\wbin\mad-admin xdpkg -i %%a
+
 
+
(yes, sadly, xpkg can install only one package at a time, so you will need to repeat this for each of them)
+
  
 
=== Scratchbox install ===
 
=== Scratchbox install ===
Line 53: Line 53:
  
 
  apt-get update
 
  apt-get update
  apt-get install libqtm-11-dev
+
  apt-get install libqtm-12-dev
  
 
=== Install on actual device ===
 
=== Install on actual device ===
  
  apt-get install libqtm-11
+
  apt-get install libqtm-12
  
 
=== Usage ===
 
=== Usage ===
Line 63: Line 63:
 
For Qt to know which mobility version to use, you will need to specify the following
 
For Qt to know which mobility version to use, you will need to specify the following
 
  maemo5 {
 
  maemo5 {
   CONFIG += mobility11
+
   CONFIG += mobility12
 
  } else {
 
  } else {
 
   CONFIG += mobility
 
   CONFIG += mobility
Line 70: Line 70:
 
in your projects .pro file (instead of CONFIG += mobility). For help and discussion about this version, see the [http://talk.maemo.org/showthread.php?p=907358 maemo.org community developer thread]. Note that you don't have to have to add the config option if you are just using the QML bindings.
 
in your projects .pro file (instead of CONFIG += mobility). For help and discussion about this version, see the [http://talk.maemo.org/showthread.php?p=907358 maemo.org community developer thread]. Note that you don't have to have to add the config option if you are just using the QML bindings.
  
'''Status:'''
+
=== Mobility sensor orientation ===
  
(Ville) Confirmed to work: ''Multimedia'' ("player" demo can stream rtsp video, full screen works)
+
Note that compared to other Nokia devices, the N900 has a landscape default, i.e. the X and Y accelerometer axis' are swapped. If you would like your code to work with the same axis on all Nokia devices, insert
  
(Ville) Confirmed to work: QmlMapViewer example with qtm-12 ("import QtMobility.location 1.1", Map, MapCircle, MapMouseArea). Does *not* work with qtm-11.
+
qputenv("N900_PORTRAIT_SENSORS", "1");
  
----
+
in your main function (for details on this, see http://bugreports.qt.nokia.com/browse/QTMOBILITY-1044 )
  
= Qt Mobility 1.2.0 =
+
'''Status:'''
  
[http://maemo.org/packages/package_instance/view/fremantle_extras-devel_free_armel/libqtm-12-dev/1.2.0~tp1-0fn~fremantle0/ libqtm-12-dev package]
+
(Ville) Confirmed to work: ''Multimedia'' ("player" demo can stream rtsp video, full screen works)
  
QtMobility 1.2.0 is currently available from extras-devel and will be promoted to Extras after testing
+
(Ville) Confirmed to work: QmlMapViewer example with qtm-12 ("import QtMobility.location 1.1", Map, MapCircle, MapMouseArea). Does *not* work with qtm-11.
  
It is used in an analogous way to libqtm-11 ([http://repository.maemo.org/extras-devel/pool/fremantle/free/q/qt-mobility/libqtm-12-bearer_1.2.0~tp1-0fn~fremantle12_armel.deb bearer (legacy)],
 
[http://repository.maemo.org/extras-devel/pool/fremantle/free/q/qt-mobility/libqtm-12-contacts_1.2.0~tp1-0fn~fremantle12_armel.deb contacts],
 
[http://repository.maemo.org/extras-devel/pool/fremantle/free/q/qt-mobility/libqtm-12-connectivity_1.2.0~tp1-0fn~fremantle12_armel.deb connectivity],
 
[http://repository.maemo.org/extras-devel/pool/fremantle/free/q/qt-mobility/libqtm-12-declarative_1.2.0~tp1-0fn~fremantle12_armel.deb declarative],
 
[http://repository.maemo.org/extras-devel/pool/fremantle/free/q/qt-mobility/libqtm-12-dev_1.2.0~tp1-0fn~fremantle12_armel.deb Headers (-dev)],
 
[http://repository.maemo.org/extras-devel/pool/fremantle/free/q/qt-mobility/libqtm-12-feedback_1.2.0~tp1-0fn~fremantle12_armel.deb feedback],
 
[http://repository.maemo.org/extras-devel/pool/fremantle/free/q/qt-mobility/libqtm-12-gallery_1.2.0~tp1-0fn~fremantle12_armel.deb gallery],
 
[http://repository.maemo.org/extras-devel/pool/fremantle/free/q/qt-mobility/libqtm-12-location_1.2.0~tp1-0fn~fremantle12_armel.deb location],
 
[http://repository.maemo.org/extras-devel/pool/fremantle/free/q/qt-mobility/libqtm-12-messaging_1.2.0~tp1-0fn~fremantle12_armel.deb messaging],
 
[http://repository.maemo.org/extras-devel/pool/fremantle/free/q/qt-mobility/libqtm-12-multimedia_1.2.0~tp1-0fn~fremantle12_armel.deb multimedia],
 
[http://repository.maemo.org/extras-devel/pool/fremantle/free/q/qt-mobility/libqtm-12-organizer_1.2.0~tp1-0fn~fremantle12_armel.deb organizer],
 
[http://repository.maemo.org/extras-devel/pool/fremantle/free/q/qt-mobility/libqtm-12-publishsubscribe_1.2.0~tp1-0fn~fremantle12_armel.deb publishsubscribe],
 
[http://repository.maemo.org/extras-devel/pool/fremantle/free/q/qt-mobility/libqtm-12-sensors_1.2.0~tp1-0fn~fremantle12_armel.deb sensors],
 
[http://repository.maemo.org/extras-devel/pool/fremantle/free/q/qt-mobility/libqtm-12-serviceframework_1.2.0~tp1-0fn~fremantle12_armel.deb serviceframework],
 
[http://repository.maemo.org/extras-devel/pool/fremantle/free/q/qt-mobility/libqtm-12-systeminfo_1.2.0~tp1-0fn~fremantle12_armel.deb systeminfo],
 
[http://repository.maemo.org/extras-devel/pool/fremantle/free/q/qt-mobility/libqtm-12-versit_1.2.0~tp1-0fn~fremantle12_armel.deb versit]):
 
  
apt-get install libqtm-12-dev
+
= Using the libraries from QML =
  
in scratchbox and
+
If you want to use the QML components of Qt Mobility, you have to add their paths to the QML search path. For the '''qmlviewer''' application, you can use the <code>-I /opt/qtm12/imports</code> command line parameter. In C++, you can do something like this:
  
  apt-get install libqtm-12
+
  viewer.engine()->addImportPath(QString("/opt/qtm12/imports"));
 
+
  viewer.engine()->addPluginPath(QString("/opt/qtm12/plugins"));
on the device, and in you .pro file you need:
+
 
+
  maemo5 {
+
  CONFIG += mobility12
+
} else {
+
  CONFIG += mobility
+
}
+
NOTE: The 1.2 release is in a '''TECH PREVIEW''' status. APIs can change and/or break without notice.
+
----
+
 
+
= Using the libraries from QML =
+
  
If you want to use the QML components of Qt Mobility, you have to add their paths to the QML search path. For the '''qmlviewer''' application, you can use the <code>-I /opt/qtm11/imports</code> command line parameter. In C++, you can do something like this:
+
If you are using PySide, you can achieve the same using:
  
  viewer.engine()->addImportPath(QString("/opt/qtm11/imports"));
+
  viewer.engine().addImportPath('/opt/qtm12/imports')
  viewer.engine()->addPluginPath(QString("/opt/qtm11/plugins"));
+
  viewer.engine().addPluginPath('/opt/qtm12/plugins')
  
For Qt Mobility 1.2, just replace "qtm11" with "qtm12" in the above text. If you are using PySide, you can achieve the same using:
 
  
viewer.engine().addImportPath('/opt/qtm11/imports')
+
= Qt Mobility 1.1 =
viewer.engine().addPluginPath('/opt/qtm11/plugins')
+
  
Again, replace "qtm11" with "qtm12" if you are using Qt Mobility 1.2.
+
Qt Mobility 1.1.x on Maemo5 is no longer maintained. Please use 1.2.x[[Category:MeeGo Harmattan]] [[Category:Symbian]]

Revision as of 01:52, 26 July 2012

Article Metadata
Article
Created: achipa (31 Dec 2010)
Last edited: hamishwillee (26 Jul 2012)

This article explains how to get and install the latest community supported versions of Qt and Qt Mobility for Maemo 5 from the Extras-devel repository.

Note that these libraries cannot be used for publishing software to Ovi nor do they come with any warranty, but are good for evaluating real-life performance and behavior. They are installed in parallel to the Maemo5 libraries, so they pose minimal danger to your existing install and do not affect stable software written for Maemo.

NOTE: All the packages referenced are found in extras-devel

Contents

Qt Mobility 1.2

libqtm-12-dev package

Both QtSDK and Scratchbox environments are supported and the 1.2 mobility packages are available from Extras. Use the environment you're more familiar with.

QtSDK install

Download the mobility packages from maemo.org (deb package here)

Open a shell prompt and go to the directory with the downloaded files and install them into your rootstrap with:

Linux

/path/to/your/QtSDK/Maemo/4.6.2/bin/mad-admin xdpkg -i libqtm-12-dev_1.2.0+git20111104-0nd~fremantle5_armel.deb 
/path/to/your/QtSDK/Maemo/4.6.2/bin/mad-admin xdpkg -i libqtm-12_1.2.0+git20111104-0nd~fremantle5_armel.deb

Windows

\path\to\your\QtSDK\Maemo\4.6.2\wbin\mad-admin.cmd xdpkg -i libqtm-12-dev_1.2.0+git20111104-0nd~fremantle5_armel.deb
\path\to\your\QtSDK\Maemo\4.6.2\wbin\mad-admin.cmd xdpkg -i libqtm-12_1.2.0+git20111104-0nd~fremantle5_armel.deb

Scratchbox install

Make sure extras-devel is enabled in you repositories, and do

apt-get update
apt-get install libqtm-12-dev

Install on actual device

apt-get install libqtm-12

Usage

For Qt to know which mobility version to use, you will need to specify the following

maemo5 {
  CONFIG += mobility12
} else {
  CONFIG += mobility
}

in your projects .pro file (instead of CONFIG += mobility). For help and discussion about this version, see the maemo.org community developer thread. Note that you don't have to have to add the config option if you are just using the QML bindings.

Mobility sensor orientation

Note that compared to other Nokia devices, the N900 has a landscape default, i.e. the X and Y accelerometer axis' are swapped. If you would like your code to work with the same axis on all Nokia devices, insert

qputenv("N900_PORTRAIT_SENSORS", "1");

in your main function (for details on this, see http://bugreports.qt.nokia.com/browse/QTMOBILITY-1044 )

Status:

(Ville) Confirmed to work: Multimedia ("player" demo can stream rtsp video, full screen works)

(Ville) Confirmed to work: QmlMapViewer example with qtm-12 ("import QtMobility.location 1.1", Map, MapCircle, MapMouseArea). Does *not* work with qtm-11.


Using the libraries from QML

If you want to use the QML components of Qt Mobility, you have to add their paths to the QML search path. For the qmlviewer application, you can use the
-I /opt/qtm12/imports
command line parameter. In C++, you can do something like this:
viewer.engine()->addImportPath(QString("/opt/qtm12/imports"));
viewer.engine()->addPluginPath(QString("/opt/qtm12/plugins"));

If you are using PySide, you can achieve the same using:

viewer.engine().addImportPath('/opt/qtm12/imports')
viewer.engine().addPluginPath('/opt/qtm12/plugins')


Qt Mobility 1.1

Qt Mobility 1.1.x on Maemo5 is no longer maintained. Please use 1.2.x

235 page views in the last 30 days.