summaryrefslogtreecommitdiffstats
path: root/src/corelib/Qt6AndroidMacros.cmake
diff options
context:
space:
mode:
authorAlexey Edelev <alexey.edelev@qt.io>2021-10-27 13:34:46 +0200
committerAlexey Edelev <alexey.edelev@qt.io>2021-10-29 14:53:56 +0200
commit53ffa665d0aba0675dccd2876257ba0e4375dd25 (patch)
treedbc38722043108740e7205a051c8a84eb2f1472c /src/corelib/Qt6AndroidMacros.cmake
parentd273f387265ded4e33fff2c4452e6a03de4792b7 (diff)
Fix target existence check in qt6_android_generate_deployment_settings
Move the check to the beginning of the function. Pick-to: 6.2 Change-Id: Ia44bb2e56626b00e75efabf2ebdc8eb97eee0ff8 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io> Reviewed-by: Craig Scott <craig.scott@qt.io>
Diffstat (limited to 'src/corelib/Qt6AndroidMacros.cmake')
-rw-r--r--src/corelib/Qt6AndroidMacros.cmake11
1 files changed, 5 insertions, 6 deletions
diff --git a/src/corelib/Qt6AndroidMacros.cmake b/src/corelib/Qt6AndroidMacros.cmake
index 74f5fc1913..58343d998c 100644
--- a/src/corelib/Qt6AndroidMacros.cmake
+++ b/src/corelib/Qt6AndroidMacros.cmake
@@ -19,6 +19,11 @@ endfunction()
# Generate the deployment settings json file for a cmake target.
function(qt6_android_generate_deployment_settings target)
+ # Information extracted from mkspecs/features/android/android_deployment_settings.prf
+ if (NOT TARGET ${target})
+ message(FATAL_ERROR "${target} is not a cmake target")
+ endif()
+
# When parsing JSON file format backslashes and follow up symbols are regarded as special
# characters. This puts Windows path format into a trouble.
# _qt_internal_android_format_deployment_paths converts sensitive paths to the CMake format
@@ -36,12 +41,6 @@ function(qt6_android_generate_deployment_settings target)
_qt_is_android_generate_deployment_settings_called TRUE
)
- # Information extracted from mkspecs/features/android/android_deployment_settings.prf
- if (NOT TARGET ${target})
- message(SEND_ERROR "${target} is not a cmake target")
- return()
- endif()
-
get_target_property(target_type ${target} TYPE)
if (NOT "${target_type}" STREQUAL "MODULE_LIBRARY")