How to set ndk path in Qt Creator for android? - android

I have downloaded the android NDK 23b latest version and unzip it in Ubuntu. I have the set the correct path in Qt Creator but it is still showing the error as shown in the image.

Qt versions depend on different NDK versions. That's why you cannot directly download any version and expect QT to recognize latest version. Qt says
Try to install NDK through Qt options screens.

Related

Qt Missing compiler for Android

I am trying to setup Qt so that I can build & deploy from my Windows 10 machine, to an Android tablet.
However from Tools>Options>Kits>Qt Versions... I get "No compiler can produce code for this Qt version. Please define one or more compilers for x86-linux-android-elf-32bit".
(or instead of 'x86-linux...' it says 'arm-linux-android-elf-32bi't or 'arm-linux-android-elf-64bit', depending on the Qt version I have selected in this window).
Do I need to manually add C and C++ compilers for the Android SDK/NDK to Qt? Where would I find these?
I have installed:
Qt: 5.12.0
Qt Creator: 4.7.0 (Community)
Android SDK: 3.2.1 64-bit Windows.
Android NDK: r18b Windows 64-bit.
Java JDK: Java SE Development Kit 8u191
From Qt Maintenance tool, Installed Qt 5.12.0 for Android x86, ARM64-v8a, ARMv7:
Within Qt Creator Tools>Options>Devices>Android I have set the paths of the JDK, SDK, & NDK and run "Update Installed":
If I go to Tools>Options>Kits>Qt Versions I see several versions, each is missing a compiler (compiler varies based on version):
But in Compilers, here is all I see:
In looking through the NDK I did see these, are these related to what I am looking for?:
When I update my QtCreator(community) from 4.7.1 to 4.9.1, everything is ok.

Controlling the chosen Android NDK platform version in Qt for Android

How do I put it to QMake to correctly generate the Makefiles to use the android platform-version I desire? I am trying to use NDK 14b with platform 21, however QMake always generates makefiles which target version 16 (which misses the stuff I need).
I'm using Qt 5.9.1 with Qt for Android Extras. I'm building to Android, armabiv7a with GCC 4.9. I am on Android NDK version 14b (which is a bit older, but definitely has support for platform 21).
I have specified
The sysroot for the Android Kit points to the folder for android-21
The android build SDK is android-26
There is an android manifest file. It sets the minimum required SDK to API 21, the Target SDK to API 24.
Qt Creator does not voice any qualms about the Kit (although I am suffering from the issue that it spam-generates defunct android kits en masse, but I do not believe this to be related to the problem I'm having here).
Am I missing something here?
The trick is to set the environment variable ANDROID_NDK_PLATFORM to android-21 this can be done in Qt Creator in the project tab. I had to force a clean after doing this before it worked.

Qt is not detecting android kits automaticallly

I am an absolute beginner. I want to install Qt for android development.
I followed the instructions for installing Qt as specified on Qt's website. I installed android manager and set up SDK, NDK, ant and JDK. After this I specified there locations in Qt but Qt is not detecting any kits at all. Why? Is there something that i am missing?
It might help to know that I an running Qt on ubuntu 16.04.3 and my Qt's version is Qt Creator (community) open source free
If I manually add a kit what should I do about sysroot and other empty fields.
What do i do about the empty fields
I have the similar problem. Problem was with NDK version.
The newest NDK version doesn't contains executable gcc compilers (it use clang compiler). I must use NDK version 15.
I had to configure manually as well for embedded linux.. To configure manually, in case you did all the configuration to a new qt, i just gotta select your compiler and change the qt version to the one you configured for the cross compiler. All the other option, let by default. Make sure your cross compiler command is set in your PATH.
This qt version is the path to your qmake.

Qt versions for 6 architectures are missing

I have just installed Qt 5.9.1 and want to make an app for Android (I'm using Windows 10).
I have installed the SDK, NDK and ant and specified the paths in the configuration. But Qt gives the following warning:
Qt versions for 6 architectures are missing. To add the Qt versions,
select Options > Build & Run > Qt Versions
When I go to Qt Versions I can only see Qt 5.9.1 MinGW 32bit.
I've googled this and a solution to a similar issue was to download the Android version of Qt from the Qt download page:
But that Android version is only 5.6. I'm gonna use Qt Quick Controls 2, which is not available until version 5.7, according to this:
Qt Quick Controls 2 provides a set of controls that can be used to
build complete interfaces in Qt Quick. The module was introduced in Qt
5.7.
Does anyone know what is causing this? Is there some other way I can get the files needed to build for Android and keep Qt version 5.9?

how to configure Qt for android

I am using Debian Linux and I want to configure Qt for Android application.
I downloaded Qt from the Qt site and configured JDK, SDK and NDK and gave the path of SDK and NDK path to Qt option, then I restarted Qt creator. But in Debuggers option Qt says:
/home/user/Qtrequirement/android-ndk-r10e/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/bin/arm-linux-androideabi-gdb not exist.
I searched in Google and I found out another NDK at Qt official that has a gdb file but not have every file for NDK. Qt says this is not top level NDK folder.
I googled everything and installed every dependency package that Qt uses.
Can anyone give me any solution that makes apk file and run in any Android device?
FYI any other application that does not use Android will run successfully, but I can not make an apk file using Qt.
Does anyone know the answer for this problem for Debian Linux?

Categories

Resources