Qt Enterprise Trial for Android not working



  • OK. Followed all the download and install directions.

    Downloaded the Qt Enterprise trial.

    Configured the Android stuff in Qt to point to the NDK and SDK locations.

    Connected a Nexus7 via USB.

    Trying to compile and run the Example: qmlqtsensors

    Errors during build process on cannot find stdlib.h

    ---Qt compile error msg
    /Developer/Android-NDK/android-ndk-r10b/sources/cxx-stl/gnu-libstdc++/4.9/include/cstdlib:72: error: stdlib.h: No such file or directory
    #include <stdlib.h>

    I searched for the stdlib.h and found it in a "/tr1" folder..a subdirectory to the include

    I searched for the stdlib.h and found it in a "/tr1" folder..a subdirectory to the include

    Changed the #include <stdlib.h> statement in the cstdlib file to #include <tr1/stdlib.h>

    No error on stdlib.h. Now I get..

    ---Qt complie new error
    /Developer/Android-NDK/android-ndk-r10b/sources/cxx-stl/gnu-libstdc++/4.9/include/cmath:44: error: math.h: No such file or directory
    #include <math.h>

    In the Sources folder for the NDK I found qmath.h tclmath.h clsMath.h..but NO math.h...

    I used the Android SDK manager to try and install all the source packages. No Joy.

    Shouldn't the example shipped with the Enterprise Trial just work..or is this expecting too much.

    New to Android development. Have used Qt for ~3yrs.

    What am I doing wrong?


  • Lifetime Qt Champion

    Hi,

    Maybe "this":http://qt-project.org/forums/viewthread/45095 might help



  • Thx a bunch!! That fixed the compile problem. Not sure why I picked the _64 version of the NDK. I thought Android documentation suggested NDK and SDK should be the _64 version..oh well.

    The example compiles and tries to deploy..you see the Nexus7 start the qmlqtsensors app..the screen blanks with the "qmlqtsensors" in the app title bar..then white screen. The deploy process halts with the following error...


    Starting remote process.D/dalvikvm(15958): Late-enabling CheckJNI
    D/dalvikvm(15958): GC_CONCURRENT freed 230K, 3% free 9080K/9336K, paused 2ms+1ms, total 17ms
    D/dalvikvm(15958): GC_CONCURRENT freed 410K, 5% free 9096K/9532K, paused 1ms+3ms, total 20ms
    D/dalvikvm(15958): Trying to load lib /data/data/org.qtproject.example.qmlqtsensors/lib/libgnustl_shared.so 0x41dec0c0
    D/dalvikvm(15958): Added shared lib /data/data/org.qtproject.example.qmlqtsensors/lib/libgnustl_shared.so 0x41dec0c0
    D/dalvikvm(15958): No JNI_OnLoad found in /data/data/org.qtproject.example.qmlqtsensors/lib/libgnustl_shared.so 0x41dec0c0, skipping init
    D/dalvikvm(15958): Trying to load lib /data/data/org.qtproject.example.qmlqtsensors/lib/libQt5Core.so 0x41dec0c0
    D/dalvikvm(15958): Added shared lib /data/data/org.qtproject.example.qmlqtsensors/lib/libQt5Core.so 0x41dec0c0
    D/dalvikvm(15958): GC_CONCURRENT freed 404K, 5% free 9095K/9572K, paused 2ms+1ms, total 15ms
    D/dalvikvm(15958): Trying to load lib /data/data/org.qtproject.example.qmlqtsensors/lib/libQt5Network.so 0x41dec0c0
    D/dalvikvm(15958): Added shared lib /data/data/org.qtproject.example.qmlqtsensors/lib/libQt5Network.so 0x41dec0c0
    D/dalvikvm(15958): No JNI_OnLoad found in /data/data/org.qtproject.example.qmlqtsensors/lib/libQt5Network.so 0x41dec0c0, skipping init
    D/dalvikvm(15958): Trying to load lib /data/data/org.qtproject.example.qmlqtsensors/lib/libQt5Qml.so 0x41dec0c0
    D/dalvikvm(15958): Added shared lib /data/data/org.qtproject.example.qmlqtsensors/lib/libQt5Qml.so 0x41dec0c0
    D/dalvikvm(15958): No JNI_OnLoad found in /data/data/org.qtproject.example.qmlqtsensors/lib/libQt5Qml.so 0x41dec0c0, skipping init
    D/dalvikvm(15958): Trying to load lib /data/data/org.qtproject.example.qmlqtsensors/lib/libQt5Gui.so 0x41dec0c0
    D/dalvikvm(15958): Added shared lib /data/data/org.qtproject.example.qmlqtsensors/lib/libQt5Gui.so 0x41dec0c0
    D/dalvikvm(15958): No JNI_OnLoad found in /data/data/org.qtproject.example.qmlqtsensors/lib/libQt5Gui.so 0x41dec0c0, skipping init
    D/dalvikvm(15958): Trying to load lib /data/data/org.qtproject.example.qmlqtsensors/lib/libQt5Quick.so 0x41dec0c0
    D/dalvikvm(15958): Added shared lib /data/data/org.qtproject.example.qmlqtsensors/lib/libQt5Quick.so 0x41dec0c0
    D/dalvikvm(15958): No JNI_OnLoad found in /data/data/org.qtproject.example.qmlqtsensors/lib/libQt5Quick.so 0x41dec0c0, skipping init
    D/dalvikvm(15958): Trying to load lib /data/data/org.qtproject.example.qmlqtsensors/lib/libQt5QuickParticles.so 0x41dec0c0
    D/dalvikvm(15958): Added shared lib /data/data/org.qtproject.example.qmlqtsensors/lib/libQt5QuickParticles.so 0x41dec0c0
    D/dalvikvm(15958): No JNI_OnLoad found in /data/data/org.qtproject.example.qmlqtsensors/lib/libQt5QuickParticles.so 0x41dec0c0, skipping init
    D/dalvikvm(15958): Trying to load lib /data/data/org.qtproject.example.qmlqtsensors/qt-reserved-files/plugins/platforms/android/libqtforandroid.so 0x41dec0c0
    D/dalvikvm(15958): Added shared lib /data/data/org.qtproject.example.qmlqtsensors/qt-reserved-files/plugins/platforms/android/libqtforandroid.so 0x41dec0c0
    I/Qt (15958): qt start
    D/dalvikvm(15958): Trying to load lib /data/data/org.qtproject.example.qmlqtsensors/lib/libQt5QuickParticles.so 0x41dec0c0
    D/dalvikvm(15958): Shared lib '/data/data/org.qtproject.example.qmlqtsensors/lib/libQt5QuickParticles.so' already loaded in same CL 0x41dec0c0
    D/dalvikvm(15958): Trying to load lib /data/app-lib/org.qtproject.example.qmlqtsensors-1/libqmlqtsensors.so 0x41dec0c0
    D/dalvikvm(15958): Added shared lib /data/app-lib/org.qtproject.example.qmlqtsensors-1/libqmlqtsensors.so 0x41dec0c0
    D/dalvikvm(15958): No JNI_OnLoad found in /data/app-lib/org.qtproject.example.qmlqtsensors-1/libqmlqtsensors.so 0x41dec0c0, skipping init
    D/libEGL (15958): loaded /system/lib/egl/libEGL_adreno200.so
    D/libEGL (15958): loaded /system/lib/egl/libGLESv1_CM_adreno200.so
    D/libEGL (15958): loaded /system/lib/egl/libGLESv2_adreno200.so
    I/Adreno200-EGL(15958): <qeglDrvAPI_eglInitialize:265>: EGL 1.4 QUALCOMM Build: Iabe52cfaeae4c5fab1acacfe6f056ba15fa93274
    D/OpenGLRenderer(15958): Enabling debug mode 0
    W/Qt (15958): qrc:///qmlqtsensors.qml:91 ((null)): qrc:///qmlqtsensors.qml:91:1: module "QtSensors" plugin "declarative_sensors" not found


  • Lifetime Qt Champion

    It seems that the Qt sensor plugin for QML has not been deployed with your app



  • Understood.

    But that bodes the question "why not". Is it the "example" project that is missing something or is it something related to my specific dev envrioment or setup? MacbookPro Nexus7.

    All the other examples I've tried have worked fine.

    I even download a Qt Accelerometer example from...

    http://developer.nokia.com/community/wiki/Accelerometer_Sensor_Example_Using_QtMobility_Project

    ... that uses the sensors, and with minimal effort, had it compiling and running.

    Is the issue that the project that does not work is QML based or is possibly incomplete in some way? Admittedly, I know zip about QML.


  • Lifetime Qt Champion

    Well.. Not knowing your project at all, I can't tell. However, you can compare your pro/pri files with the ones for the examples that you got working to see if there's something different


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.