Home:ALL Converter>Error building Qt app for Android with Qt Creator

Error building Qt app for Android with Qt Creator

Ask Time:2019-01-10T10:27:43         Author:sungyong

Json Formatter

When I tried to build QtFireExample with my QtCreator, failed with below error message.

The installed SDK tools version (26.1.1) does not include Gradle scripts. The minimum Qt version required for Gradle build to work is 5.9.0/5.6.3 Error while building/deploying project QtFirebaseExample (kit: Android) When executing step "Build Android APK"

My android studio is 3.2.1. And SDK tools 26.1 is also installed.
qt version is also above 5.9.0
What I did mistake?

❯ qmake --version
QMake version 3.1
Using Qt version 5.12.0 in /usr/local/Cellar/qt/5.12.0/lib

Author:sungyong,eproduced under the CC 4.0 BY-SA copyright license with a link to the original source and this disclaimer.
Link to original article:https://stackoverflow.com/questions/54121165/error-building-qt-app-for-android-with-qt-creator
jpo38 :

There's more steps to follow before you can deploy your first Android app using QtCreator. Installing SDK tools is not enough. Here is what I did, I'm using Windows, but hopefully the steps are the same under Ubuntu.\n\n\nInstall QtCreator using the link provided by Hitokage, include QtCreator (I got version 4.8.0), and Qt 5.12.0 binaries for your platform + needed Android (armv7, x86...)\nGet JDK 1.8.X.X\nGet NDK r18b (or a more recent version)\nGet SDK tools 26.1.1 (what you already did)\nSDK tools itself is not enough, some SDK modules must be installed, from SDK tools folder, run:\n\n\nsdkmanager platform-tools\nsdkmanager build-tools;28.0.3\nsdkmanager extras;google;usb_driver\nsdkmanager platforms;android-22 (which is enough for me, you may want something different based on your target Android devices)\n\n\n\nThen open QtCreator, Go to \"Mobile devices\" (my french version calls it \"Appareils mobiles\"), then make it point to installed JDK, SDK, NDK, clic Apply and then kits should be automtically created. Now you are ready to compile and deploy and Android app for API 22.\n\nNote that gradle is automatically downloaded by QtCreator first time you'll request a deployment.",
2019-01-21T08:30:20
yy