summaryrefslogtreecommitdiffstats
path: root/cmake
diff options
context:
space:
mode:
authorTinja Paavoseppä <tinja.paavoseppa@qt.io>2022-01-19 13:35:50 +0200
committerTinja Paavoseppä <tinja.paavoseppa@qt.io>2022-05-20 08:08:02 +0300
commit9af1f3557a60e37f8b7bafb921d265d322f1fc16 (patch)
tree8a4b2ef422b02627e9d2055439b8489d1c40b652 /cmake
parentff153d9874f728c9ec3ab40b87f55ccf0239e538 (diff)
Add option to not include native libraries in APK
Sometimes it is not desirable to include the libraries in the APK, e.g. system and vendor apps could prefer having one set of libraries installed on the device. If unbundled deployment is specified, native libraries will not be included in the APK. With unbundled deployment, optional arguments can be passed to set the path to load the libraries on the device. [ChangeLog][Android][Deployment Changes] Adds option for Unbundled deployment, where native libraries are not packaged in the APK. Task-number: QAA-771 Change-Id: Ica51ef83a24dad58c7586bf610a58abe21fc1100 Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
Diffstat (limited to 'cmake')
-rw-r--r--cmake/QtPlatformAndroid.cmake18
1 files changed, 18 insertions, 0 deletions
diff --git a/cmake/QtPlatformAndroid.cmake b/cmake/QtPlatformAndroid.cmake
index 6e07477332..a14c5626b3 100644
--- a/cmake/QtPlatformAndroid.cmake
+++ b/cmake/QtPlatformAndroid.cmake
@@ -163,6 +163,24 @@ define_property(TARGET
"This variable points to the path of the deployment settings JSON file, which holds properties required by androiddeployqt to package the Android app."
)
+define_property(TARGET
+ PROPERTY
+ QT_ANDROID_SYSTEM_LIBS_PREFIX
+ BRIEF_DOCS
+ "This variable is used to specify a path to Qt libraries on the target device in Android."
+ FULL_DOCS
+ "This variable can be used to provide a custom system library path to use for library loading lookup on Android. This is necessary when using Qt libraries installed outside an app's default native (JNI) library directory."
+)
+
+define_property(TARGET
+ PROPERTY
+ QT_ANDROID_NO_DEPLOY_QT_LIBS
+ BRIEF_DOCS
+ "This variable is used to control whether Qt libraries should be deployed inside the APK on Android."
+ FULL_DOCS
+ "This variable can be used to exclude Qt shared libraries from being packaged inside the APK when deploying on Android. Not supported when deploying as Android Application Bundle."
+)
+
# Returns test execution arguments for Android targets
function(qt_internal_android_test_arguments target out_test_runner out_test_arguments)
set(${out_test_runner} "${QT_HOST_PATH}/${QT${PROJECT_VERSION_MAJOR}_HOST_INFO_BINDIR}/androidtestrunner" PARENT_SCOPE)