Details
-
Bug
-
Resolution: Fixed
-
P2: Important
-
6.6
-
None
-
Windows host, x86_64 and arm7 and 8 affected Android targets
At 6.6.0 qt creator 11.02
-
-
9349e463d (dev), 416081ef4 (6.6), 88d62ca1a (6.5), 2faaa1dc0 (tqtc/lts-6.2)
Description
Description
When building for Android Examples with
set_target_properties(examplename PROPERTIES
#Prevent name clash with build subdirectory on case-insensitive file systems
OUTPUT_NAME examplename
)
we get the warning
C:\Qt\6.6.0\android_x86_64\lib\cmake\Qt6Core\Qt6CoreMacros.cmake:2754: warning: Qt policy QTP0002 is not set: Target properties that specify android-specific paths may contain generator expressions but they must evaluate to valid JSON strings. Check https://doc.qt.io/qt-6/qt-cmake-policy-qtp0002.html for policy details. Use the qt_policy command to set the policy and suppress this warning. C:/Qt/6.6.0/android_x86_64/lib/cmake/Qt6Core/Qt6AndroidMacros.cmake:926 (__qt_internal_setup_policy) C:/Qt/6.6.0/android_x86_64/lib/cmake/Qt6Core/Qt6AndroidMacros.cmake:65 (_qt_internal_android_format_deployment_paths) C:/Qt/6.6.0/android_x86_64/lib/cmake/Qt6Core/Qt6AndroidMacros.cmake:1352 (qt6_android_generate_deployment_settings) C:/Qt/6.6.0/android_x86_64/lib/cmake/Qt6Core/Qt6CoreMacros.cmake:651 (_qt_internal_android_executable_finalizer) C:/Qt/6.6.0/android_x86_64/lib/cmake/Qt6Core/Qt6CoreMacros.cmake:651 (cmake_language) C:/Qt/6.6.0/android_x86_64/lib/cmake/Qt6Core/Qt6CoreMacros.cmake:745 (_qt_internal_finalize_executable) C:/Qt/6.6.0/android_x86_64/lib/cmake/Qt6Core/Qt6CoreMacros.cmake:715:EVAL:1 (qt6_finalize_target) CMakeLists.txt:DEFERRED
Then the error "Target is not an application so not building an APK"
and then "Cannot read from deployment settings json"
Investigation:
So, setting the policy fixes this:
qt_policy(SET QTP0002 NEW)
Examples affected
Attachments
Issue Links
- relates to
-
QTBUG-117515 [Scene Graph] Cannot build any example on Android where rendering is used under QML
- Reported
-
QTBUG-113411 Vulkan under qml example will not build for android on Windows
- Closed
For Gerrit Dashboard: QTBUG-117509 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
507039,4 | Use the actual target name as base name for android deployment settings | dev | qt/qtbase | Status: MERGED | +2 | 0 |
507765,2 | Use the actual target name as base name for android deployment settings | 6.6 | qt/qtbase | Status: MERGED | +2 | 0 |
507803,2 | Use the actual target name as base name for android deployment settings | 6.5 | qt/qtbase | Status: MERGED | +2 | 0 |
507925,4 | Use the actual target name as base name for android deployment settings | tqtc/lts-6.2 | qt/tqtc-qtbase | Status: MERGED | +2 | 0 |