Attempting to deploy android app: ABI is incompatible, device supports ABIs
-
Ok, found adb, started it, now when I try to deploy I get this compile error
Deploying to ZY2233FMDC Cannot find the androiddeploy Json file. Error while building/deploying project TestSwipeApp (kit: Android for armeabi-v7a (Clang Qt 5.11.2 for Android ARMv7)) When executing step "Deploy to Android device"
I honestly really thought this would be easier. It's very frustrating.
I'm also concerned about, how do I just build an APK? I'm just realizing I can't compile an APK with QtCreator because it refuses to compile. When you first open an android project you get all these errors:
/bin/sh: 1: ~/Android/android-ndk-r20/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/bin/arm-linux-androideabi-g++: not found Project ERROR: Cannot run target compiler '~/Android/android-ndk-r20/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/bin/arm-linux-androideabi-g++'. Output: =================== /bin/sh: 1: ~/Android/android-ndk-r20/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/bin/arm-linux-androideabi-g++: not found =================== Maybe you forgot to setup the environment? Error while parsing file ~/development/TestSwipeApp/TestSwipeApp.pro. Giving up.
It's correct, there is no arm-linux-androideabi-g++ but nor can I find a download for such. Why is this missing from the standard NDK? It's got over a dozen other builders in bin but not the one needed on a 64bit Linux system? What's up with that?
-
Ok, found adb, started it, now when I try to deploy I get this compile error
Deploying to ZY2233FMDC Cannot find the androiddeploy Json file. Error while building/deploying project TestSwipeApp (kit: Android for armeabi-v7a (Clang Qt 5.11.2 for Android ARMv7)) When executing step "Deploy to Android device"
I honestly really thought this would be easier. It's very frustrating.
I'm also concerned about, how do I just build an APK? I'm just realizing I can't compile an APK with QtCreator because it refuses to compile. When you first open an android project you get all these errors:
/bin/sh: 1: ~/Android/android-ndk-r20/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/bin/arm-linux-androideabi-g++: not found Project ERROR: Cannot run target compiler '~/Android/android-ndk-r20/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/bin/arm-linux-androideabi-g++'. Output: =================== /bin/sh: 1: ~/Android/android-ndk-r20/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/bin/arm-linux-androideabi-g++: not found =================== Maybe you forgot to setup the environment? Error while parsing file ~/development/TestSwipeApp/TestSwipeApp.pro. Giving up.
It's correct, there is no arm-linux-androideabi-g++ but nor can I find a download for such. Why is this missing from the standard NDK? It's got over a dozen other builders in bin but not the one needed on a 64bit Linux system? What's up with that?
@graniteDev Based on the log, you are using
Qt 5.11.2
withNDK 20
which are not compatible.
ForQt 5.11.2
useNDK 17c
, can be downloaded from the archives from android. Or update toQt 5.12.4
snd useNDK 19c
asNDK 20
isn't supported yet.Additionally if you use
NDK 17c
make sure that in your.pro
file you useandroid-g++
or forNDK 19c
android-clang
(if you don't see any of that in the pro file ignore it for now)The
apk
is usually found in the build folder that Qt makes, I don't remember the exact file path, but once the build is successful it will be there. -
How did you know that it was incompatible? The kit gave no indication, nor did the device/android setup give any indication that it was a problem.
I'm farther now, but still failing to build an APK when I ask it to build for Android
13:41:01: The process "~Android/android-ndk-r17c/prebuilt/linux-x86_64/bin/make" exited normally. 13:41:01: No application .pro file found, not building an APK. 13:41:01: Elapsed time: 00:00.
When trying to deploy to the phone, with ADB running the phone now is compatible - again here I blame Qt for not making the error more obvious. It should be able to detect that ADB was not running. However I get all these errors:
adb: failed to stat ~/development/build-TestSwipeApp-Android_for_armeabi_v7a_Clang_Qt_5_11_2_for_Android_ARMv7-Release/android-build//build/outputs/apk/android-build-debug.apk: No such file or directory Installing to device failed! Installing Android package to device. Running command "~/Android/Sdk/platform-tools/adb -s ZY2233FMDC install -r ~/development/build-TestSwipeApp-Android_for_armeabi_v7a_Clang_Qt_5_11_2_for_Android_ARMv7-Release/android-build//build/outputs/apk/android-build-debug.apk" Performing Streamed Install 13:43:15: The process "~/Qt/5.11.2/android_armv7/bin/androiddeployqt" exited with code 16. 13:43:15: Pulling files necessary for debugging. 13:43:15: Package deploy: Running command "~/Android/Sdk/platform-tools/adb -s ZY2233FMDC pull /system/bin/app_process ~/development/build-TestSwipeApp-Android_for_armeabi_v7a_Clang_Qt_5_11_2_for_Android_ARMv7-Release/app_process". 13:43:15: Package deploy: Running command "~/Android/Sdk/platform-tools/adb -s ZY2233FMDC pull /system/bin/app_process32 ~/development/build-TestSwipeApp-Android_for_armeabi_v7a_Clang_Qt_5_11_2_for_Android_ARMv7-Release/app_process". 13:43:15: Package deploy: Running command "~/Android/Sdk/platform-tools/adb -s ZY2233FMDC pull /system/bin/linker ~/development/build-TestSwipeApp-Android_for_armeabi_v7a_Clang_Qt_5_11_2_for_Android_ARMv7-Release/linker". 13:43:15: Package deploy: Running command "~/Android/Sdk/platform-tools/adb -s ZY2233FMDC pull /system/lib/libc.so ~/development/build-TestSwipeApp-Android_for_armeabi_v7a_Clang_Qt_5_11_2_for_Android_ARMv7-Release/libc.so". Error while building/deploying project TestSwipeApp (kit: Android for armeabi-v7a (Clang Qt 5.11.2 for Android ARMv7)) When executing step "Deploy to Android device" 13:43:15: Elapsed time: 00:01.
-
You say to use android-g++ in the .pro file, but how? You need to be more specific. Does that go under QT, CONFIG, DEFINES or something else?
-
You say to use android-g++ in the .pro file, but how? You need to be more specific. Does that go under QT, CONFIG, DEFINES or something else?
@graniteDev If you made a project (i.e. Qt quick application) you should have a
.pro
file, which here seems not to exist or can't be found.
Theandroid-g++
is only necessary if you add some additional/android only libs, for a new project that should not be the case, that's why I said u can ignore it if you don't have anything like that.In
.pro
file it looks something likeandroid-g++ { some android only includes ... }
For now just try to make a new empty qt quick application project, and try to run it on the phone. It doesn't change much, but use the
debug
version to compile till you actually want to make a release. -
I have an empty project, and it has a .pro file. I'm giving up. I tried all this week to get this to work. In 5 minutes I had a blank app on my phone with Android Studio. Qt really needs to get it's act together with this. It's shameful how awful this is.
-
I had a stupid idea to let QT Creator do update. After several hours I can't detect my devices. Good choice for Sunday.
@Marek-Pio You can install an older version (parallel to the updated one) with the offline installers: http://download.qt.io/official_releases/qtcreator
-
@Wiru
I have simular problem. I try to use same as you say:
Qt 5.12.4
NDK 19c 64bit
QT creator 4.9.2
Windows 10
For me program strart, but in the debuging mode, breakpoint dont stop if i try to use on Android 4.4.4. If i try to start debuging on Android 9 everythings work okey. I have to use old Android version becouse we use on our system. After i start on old Android version i get message like this:08:11:14: The command "E:\Android\sdk\platform-tools\adb.exe" terminated with exit code 1. 08:11:14: Package deploy: Failed to pull "/system/bin/app_process32" to "Android_for_armeabi_v7a_Clang_Qt_5_12_4_for_Android_ARMv7-Debug/app_process".
I think the main problem that qt try to use app_process32 and he cant find it becouse on old Android version there is only app_process .
So how to change app_process32 to app_process on qt debuging mode? I try to search in google but i didnt find correct answer.
I found that i can change in ndk-gdb.py file but i change anything it have no changes....i try to delete file and load program, and it was started...so i dont understand from where are taking to load app_process32 but not app_process
-
Hello,
I faced the same problem and searched everywhere for hours. At the end found out that when i created new project i didn't add the preferred choice of devices like arm64-v8 and all other. Make sure you did while creating new project.