summaryrefslogtreecommitdiffstats
path: root/src/corelib/Qt6AndroidMacros.cmake
diff options
context:
space:
mode:
authorAssam Boudjelthia <assam.boudjelthia@qt.io>2020-08-26 17:02:12 +0300
committerAssam Boudjelthia <assam.boudjelthia@qt.io>2020-08-28 12:44:14 +0300
commit09ac1bdfc5d2ee7a537c63e54348a8cf8d905fcf (patch)
treea7c79eef5a1fc531354bbc32d58d25b83f9f07b5 /src/corelib/Qt6AndroidMacros.cmake
parent70def4341a9f34248b8c0d3edb38ad5464953b9e (diff)
Android: enable androiddeployqt to get the host's rcc binary path
Since Qt 6 CMake installs the host and target into separate directories, androiddeployqt fails to get the correct path to rcc. This change includes the host's rcc binary path in deployment-settings.json. Task-number: QTBUG-85399 Change-Id: I610bb6fea1180a119e4c0ceb75bf78c175ae430e Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
Diffstat (limited to 'src/corelib/Qt6AndroidMacros.cmake')
-rw-r--r--src/corelib/Qt6AndroidMacros.cmake13
1 files changed, 11 insertions, 2 deletions
diff --git a/src/corelib/Qt6AndroidMacros.cmake b/src/corelib/Qt6AndroidMacros.cmake
index 635a2bd559..1bfa5eab2d 100644
--- a/src/corelib/Qt6AndroidMacros.cmake
+++ b/src/corelib/Qt6AndroidMacros.cmake
@@ -157,7 +157,7 @@ endif()
" \"application-binary\": \"${target_output_name}\",\n")
# Override qmlimportscanner binary path
- set(qml_importscanner_binary_path "${QT_HOST_PATH}/bin/qmlimportscanner")
+ set(qml_importscanner_binary_path "${QT_HOST_PATH}/${QT6_HOST_INFO_BINDIR}/qmlimportscanner")
if (WIN32)
string(APPEND qml_importscanner_binary_path ".exe")
endif()
@@ -165,6 +165,15 @@ endif()
string(APPEND file_contents
" \"qml-importscanner-binary\" : \"${qml_importscanner_binary_path_native}\",\n")
+ # Override rcc binary path
+ set(rcc_binary_path "${QT_HOST_PATH}/${QT6_HOST_INFO_BINDIR}/rcc")
+ if (WIN32)
+ string(APPEND rcc_binary_path ".exe")
+ endif()
+ file(TO_NATIVE_PATH "${rcc_binary_path}" rcc_binary_path_native)
+ string(APPEND file_contents
+ " \"rcc-binary\" : \"${rcc_binary_path_native}\",\n")
+
# Last item in json file
# base location of stdlibc++, will be suffixed by androiddeploy qt
@@ -226,7 +235,7 @@ function(qt6_android_add_apk_target target)
set(should_add_to_global_apk TRUE)
endif()
- set(deployment_tool "${QT_HOST_PATH}/bin/androiddeployqt")
+ set(deployment_tool "${QT_HOST_PATH}/${QT6_HOST_INFO_BINDIR}/androiddeployqt")
set(apk_dir "$<TARGET_PROPERTY:${target},BINARY_DIR>/android-build")
add_custom_target(${target}_prepare_apk_dir
DEPENDS ${target}