Hello,
> /opt/qt4-maemo5/imports/QtMobility/ and dumped the contents of
> plugins/declarative into it. After that the declarative examples worked!
> (At least the location examples that I tested).
"Qt/imports" is a default location for QML to look for declarative plugins.
Unless you've added declarative lookup PATHs, here's where they should be.
When you write
import QtMobility.location 1.1
in your .qml, it effectively maps to a folder under the lookup directories, in
this default case:
Qt/imports/QtMobility/location
The 'make install' step for declarative-location plugin should copy the plugin
under the Qt/imports folder.
I just tested it works on my scratchbox setup, there's probably something
different between our systems.
Unfortunately I'm not familiar with multimedia, hopefully someone else can help
you with that.
(With quick grep over multimedia code my unsophisticed guess is that a plugin
is missing or not found:
QMediaService* requestService(const QByteArray &type, const
QMediaServiceProviderHint &hint) {
... tries to load plugins but fails to do so...
qWarning() << "defaultServiceProvider::requestService(): no service found
for -" << key;
})
Cheers,
Juha
-----Original Message-----
From: ext Tico Ballagas [mailto:[email protected]]
Sent: Thursday, September 16, 2010 2:19 PM
To: Vuolle Juha (Nokia-MS/Brisbane)
Cc: [email protected]
Subject: Re: [Qt-mobility-feedback] QtMobility declarative examples
Thanks for the feedback.
I verified the plugins are built and residing in plugins/declarative, but for
some reason not all of the built libraries are copied over to the install dir
on "make install".
[sbox-FREMANTLE_ARMEL: ~/qt-mobility/plugins/declarative/location] > ls
libdeclarative_location.so
libdeclarative_location.so
[sbox-FREMANTLE_ARMEL: ~/qt-mobility/plugins] > ls
Makefile declarative geoservices multimedia plugins.pro versit
contacts feedback landmarks organizer sensors
[sbox-FREMANTLE_ARMEL: ~/qt-mobility/install/plugins] > ls
contacts geoservices mediaservice playlistformats versit
feedback landmarks organizer sensors
(Notice the entire declarative directory is missing in the install/plugins
folder)
I manually copied the declarative libs into plugins/declarative/* but that
still didn't work. Finally, I created
/opt/qt4-maemo5/imports/QtMobility/ and dumped the contents of
plugins/declarative into it. After that the declarative examples worked! (At
least the location examples that I tested).
However, I ventured away from the examples and tried to experiment with the
video module in multimedia and got the following error:
Nokia-N900:/home/user/video# /opt/qt4-maemo5/bin/qmlviewer testvideo.qml
defaultServiceProvider::requestService(): no service found for -
"com.nokia.qt.mediaplayer"
Nokia-N900:/opt/qt4-maemo5/plugins/mediaservice# ls
libqgstengine.so libqtmedia_v4lengine.so
Nokia-N900:/opt/qt4-maemo5/plugins/mediaservice# echo $QT_PLUGIN_PATH
/opt/qt4-maemo5/
Any ideas how to fix this remaining issue?
Best
-Tico
On Sep 15, 2010, at 4:30 PM, <[email protected]> <[email protected]>
wrote:
> Hi Tico,
>
> Hmm... make & make install should set everything, I mean there is no separate
> configure flag to set.
>
> Here are some things worth checking:
> 1) Qt needs to be 4.7+ and configured to have declarative module. Without
> this the declarative plugins will not be compiled (nor would they compile)
> 2) QtMobility needs to have location module (either by default 'configure'
> which configures it all or 'configure -modules "location")
> You can check if the above are true by going to your mobility root folder and
> typing
> qmake -r
> and make sure that you see something like:
> Reading
> /home/juvuolle/QT/qtmobility/qtm-location/plugins/declarative/declarative.pro
> Reading
> /home/juvuolle/QT/qtmobility/qtm-location/plugins/declarative/location/location.pro
> --> if not, then either 1) or 2) is probably missing.
>
> 3) You can also manually compile the plugin, go to
> /plugins/declarative/location and make & install (as a temp solution, of
> course if there is a real configuration problem, it needs to be solved).
>
> 4) You can also tell qmlviewer where to look for the plugins by giving it the
> -I option.
> qmlviewer -I /home/opt/qt/qt/imports myapp.qml
> This shouldn't usually be the case but e.g. if I've compiled my projects in
> scratchbox, and then mount them to a different location on my N900 it may be
> useful.
>
> Hope this helps,
> Juha
>
>
> -----Original Message-----
> From: [email protected]
> [mailto:[email protected]] On Behalf Of ext Tico
> Ballagas
> Sent: Thursday, September 16, 2010 5:43 AM
> To: [email protected]
> Subject: Re: [Qt-mobility-feedback] QtMobility declarative examples
>
> After further digging, it seems like "make install" doesn't properly create
> and install the imports/QtMobility directory with related qmldir's and
> libqml*.so files. This causes the "import QtMobility" statements in the
> /examples/declarative-* to fail.
>
> How do I generate these libraries and qmldir's for testing QtMobility within
> QML? There didn't seem to be any relevant flags in the configure --help. Am
> I missing something?
>
> -Tico
>
> On Sep 14, 2010, at 12:33 AM, Tico Ballagas wrote:
>
>> Hi-
>>
>> I finally got QtMobility 1.1 to build for my N900. However, now I'm having
>> problems running the declarative examples.
>>
>> I get the following running QML_IMPORT_TRACE=1 /opt/qt4-maemo5/bin/qmlviewer:
>> QDeclarativeImportDatabase::addImportPath "/opt/qt4-maemo5/imports"
>> QDeclarativeImportDatabase::addImportPath "/opt/qt4-maemo5/bin"
>> QDeclarativeImportDatabase::addToImport 0x2d83c4 "." -1.-1 File as ""
>> QDeclarativeImportDatabase::addToImport 0x2d83c4 "Qt" 4.7 Library as ""
>> QDeclarativeImportDatabase::addToImport 0x2d83c4 "QtMobility.location" 1.1
>> Library as ""
>> file:///home/user/test.qml:2:1: module "QtMobility.location" is not
>> installed
>> import QtMobility.location 1.1
>>
>> I've installed qtmobility in /opt/qt4-maemo5/
>>
>> How do I set my environment appropriately for qmlviewer to see the
>> qtmobility libraries? Do I need to create a qmldir file for this that
>> explicitly lists all of the library files?
>>
>> Best
>> -Tico
>
>
> _______________________________________________
> Qt-mobility-feedback mailing list
> [email protected]
> http://lists.trolltech.com/mailman/listinfo/qt-mobility-feedback
_______________________________________________
Qt-mobility-feedback mailing list
[email protected]
http://lists.trolltech.com/mailman/listinfo/qt-mobility-feedback