summaryrefslogtreecommitdiffstats
path: root/src/android
diff options
context:
space:
mode:
authorAndreas Buhr <andreas.buhr@qt.io>2021-03-23 18:51:36 +0100
committerQt Cherry-pick Bot <cherrypick_bot@qt-project.org>2021-09-30 17:41:48 +0000
commit18f6c2c7eeabbbc6c268dd9649ff542fca9c4c8e (patch)
tree68c0c574f46fc4b3667f6bb4405fa511ff5f7429 /src/android
parentbf4cf5a235ab6cdd454bb3b5169d12af5fb3725d (diff)
Specify Android architecture in gradle files
When building for armeabi-v7a, building and APK using "ninja foo_make_apk" works. Building it by calling "gradlew assembleDebug" works. Opening the "android-build" folder in Android Studio and clicking the "Build" button works. But clicking the "Run" or "Debug" button in Android Studio does not work when the attached phone is arm64-v8a. Then Android Studio automatically selects the v8 architecture which does not find the Qt libraries. This patch adds explicit ABI selection to the gradle configuration files. With explicit ABI selection, Android Studio does not try to outsmart you. Fixes: QTBUG-96701 Task-number: QTBUG-87022 Change-Id: I4ad6356c38b7eca004c0e0dbbb357cab7de84c0f Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io> (cherry picked from commit 07cfab07a2a489e021b56226824a2d9b1211fad7) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Diffstat (limited to 'src/android')
-rw-r--r--src/android/templates/build.gradle1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/android/templates/build.gradle b/src/android/templates/build.gradle
index fd7ce34aa9..7a77517681 100644
--- a/src/android/templates/build.gradle
+++ b/src/android/templates/build.gradle
@@ -73,5 +73,6 @@ android {
resConfig "en"
minSdkVersion qtMinSdkVersion
targetSdkVersion qtTargetSdkVersion
+ ndk.abiFilters = qtTargetAbiList.split(",")
}
}