From 10a2a1c46e766985f28db82d17852b634a7d6504 Mon Sep 17 00:00:00 2001 From: Alexandru Croitor Date: Tue, 17 Nov 2020 17:51:42 +0100 Subject: [PATCH] CMake: Rename the qt resource properties to be internal Use lowercase underscored property names. This ensures they will continue to work even for INTERFACE libraries if it ever comes to that. Change-Id: I5281070f25c1eb9f591c79af8b7fa6169c7c0fb7 Reviewed-by: Joerg Bornemann --- cmake/QtPrlHelpers.cmake | 4 ++-- cmake/QtResourceHelpers.cmake | 4 ++-- src/corelib/Qt6CoreMacros.cmake | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/cmake/QtPrlHelpers.cmake b/cmake/QtPrlHelpers.cmake index d26b6135bf..2c0946ebad 100644 --- a/cmake/QtPrlHelpers.cmake +++ b/cmake/QtPrlHelpers.cmake @@ -115,7 +115,7 @@ function(qt_internal_walk_libs # Need to record the rcc object file info not only for dependencies, but also for # the current target too. Otherwise the saved information is incomplete for prl static # build purposes. - get_target_property(main_target_rcc_objects ${target} QT_RCC_OBJECTS) + get_target_property(main_target_rcc_objects ${target} _qt_rcc_objects) if(main_target_rcc_objects) qt_merge_libs(rcc_objects ${main_target_rcc_objects}) endif() @@ -190,7 +190,7 @@ function(qt_internal_walk_libs else() qt_merge_libs(libs "$") - get_target_property(target_rcc_objects "${lib_target}" QT_RCC_OBJECTS) + get_target_property(target_rcc_objects "${lib_target}" _qt_rcc_objects) if(target_rcc_objects) qt_merge_libs(rcc_objects ${target_rcc_objects}) endif() diff --git a/cmake/QtResourceHelpers.cmake b/cmake/QtResourceHelpers.cmake index e37cd03cd7..ff4f234306 100644 --- a/cmake/QtResourceHelpers.cmake +++ b/cmake/QtResourceHelpers.cmake @@ -28,7 +28,7 @@ endfunction() function(qt_internal_record_rcc_object_files target resource_targets) foreach(out_target ${resource_targets}) - get_target_property(resource_name ${out_target} QT_RESOURCE_NAME) + get_target_property(resource_name ${out_target} _qt_resource_name) if(NOT resource_name) continue() endif() @@ -43,7 +43,7 @@ function(qt_internal_record_rcc_object_files target resource_targets) # In a non-prefix build we use the object file paths right away. set(rcc_object_file_path $>) endif() - set_property(TARGET ${target} APPEND PROPERTY QT_RCC_OBJECTS "${rcc_object_file_path}") + set_property(TARGET ${target} APPEND PROPERTY _qt_rcc_objects "${rcc_object_file_path}") # Make sure that the target cpp files are compiled with the regular Qt internal compile # flags, needed for building iOS apps with qmake where bitcode is involved. diff --git a/src/corelib/Qt6CoreMacros.cmake b/src/corelib/Qt6CoreMacros.cmake index c70fdbef32..a200dd6c32 100644 --- a/src/corelib/Qt6CoreMacros.cmake +++ b/src/corelib/Qt6CoreMacros.cmake @@ -1061,7 +1061,7 @@ function(__qt_propagate_generated_resource target resource_name generated_source if(type STREQUAL STATIC_LIBRARY) set(resource_target "${target}_resources_${resourceName}") add_library("${resource_target}" OBJECT "${generated_source_code}") - set_property(TARGET ${resource_target} APPEND PROPERTY QT_RESOURCE_NAME ${resourceName}) + set_property(TARGET ${resource_target} APPEND PROPERTY _qt_resource_name ${resourceName}) # Use TARGET_NAME genex to map to the correct prefixed target name when it is exported # via qt_install(EXPORT), so that the consumers of the target can find the object library