Qt6 topics merged with General

QtPositioning with geoclue backend does not work on Linux

  • If I try to get a QGeoPositionInfo from the QGeoPositionInfoSource instance returned by QGeoPositionInfoSource::createDefaultSource then I get only an updateTimeout signal. I set the update interval to 5000ms and listen to the signals positionUpdated, error and updateTimeout, additionally I check the supported positioning methods and the available sources before calling startUpdates and writing the values to console. Everything looks fine, except that the signal positionUpdated is never triggered. Here is my console output:

    2015-09-29T22:02:29 - GeoPosition methods GPS/GLONASS and 3GPP/WiFi supported
    2015-09-29T22:02:29 - GeoPosition source 'geoclue' available
    2015-09-29T22:02:29 - Update interval is 5000ms
    2015-09-29T22:02:29 - GeoPosition service started
    2015-09-29T22:02:31 - GeoPosition update timeout

    I've tested it on ARCH Linux ARM on a raspberry and on Manjaro Linux 15.09 x86_64 (Qt5.5.0, geoclue 0.12.99) with LAN (eth0) and an UMTS surfstick (ppp0) connection, internet access works fine with both connections. The positioning plugins are available here:

    $ ls -l /usr/lib/qt/plugins/position/
    insgesamt 88
    -rwxr-xr-x 1 root root 35752 18. Aug 09:24 libqtposition_geoclue.so
    -rwxr-xr-x 1 root root 51904 18. Aug 09:24 libqtposition_positionpoll.so

    Does anyone know what I'm doing wrong? The Qt documentation says that it should work that way. I've a small console project for testing that I can upload, if required.

Log in to reply