Android basics: how to run a QT app on Android?



  • I am trying to learn to deploy QT apps for Android. I am able to make a simple app and run it on the simultaor in QT Creator (with necessitas of course). But there is a question for which I can't find an answer on the net: how can I run my app on my android phone?
    I tried to build the executable file and copy it on my phone, but it doesn't even know how to handle the file.
    Reading on the net, I found people talking of connecting the android mobile on the pc and run the app from QT Necessitas, but that means having the mobile connected to the PC, while I guess the whole point is to have the app to run independently on the android like any other app.
    Does anyone know how to run a qt app, deploied with QT Creator (Necessitas), on an Android phone?

    Thanks a lot in advance.



  • I haven't gotten as far as the simulator yet, but another user (Zappa) told me "it worked after you configure the project to copy over local libraries to the device." After that he was able to run on the phone, but then sound initially didn't work.



  • Does it mean that QT Necessitas, in the end, for the moment is totally useless because it does not allow to create standalone qt apps that can run on Android when the phone is not connected to a PC?
    But here on the forum I red of people that have qt apps running on Android (if I did not misunderstand) so there must be a way to create a qt standolne app that runs on Android. Or is it still a mirage?


  • Lifetime Qt Champion

    No, for development purpose, it's faster and easier to copy the local libraries to your device. If you want to debug/test your application and also copy your executable to your phone, the device must be connected to your computer.

    The applications developed either with necessitas or Qt 5.1 use the ministro application to download the needed Qt libraries to one device. This allows to have one set of libraries shared across all Qt applications.

    If you need more information about necessitas, the better place is the necessitas project page and mailing list.

    Hope this helps



  • So we should download Qt libs to android phone before download the application which is made with Qt?


  • Lifetime Qt Champion

    No it will be done for you by ministro the first time you start your application



  • Thank you. I really wonder new Qt version.


Log in to reply
 

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