summaryrefslogtreecommitdiffstats
path: root/cmake/QtInternalTargets.cmake
diff options
context:
space:
mode:
authorAlexey Edelev <alexey.edelev@qt.io>2022-01-31 18:53:57 +0100
committerAlexey Edelev <alexey.edelev@qt.io>2022-02-02 16:45:37 +0100
commitfd3341a74ecbe93c5fb931f625075b93be69b9de (patch)
treedd0df47448e832b524c91b945bfcc890607a9730 /cmake/QtInternalTargets.cmake
parent1b34ee080e0b336233d2be8422c4476569251da6 (diff)
Add qt_internal_undefine_global_definition function
qt_internal_undefine_global_definition disables an internal global definition that is defined by the qt_internal_add_global_definition function for a specific target. Remove the ability to set the custom "undefine" flag for the definitions since it's hard to control it using the introduced function. Pick-to: 6.2 6.3 Task-number: QTBUG-100334 Change-Id: Ic1637d97aa51bbdd06c5b191c57a941aa208d4dc Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Diffstat (limited to 'cmake/QtInternalTargets.cmake')
-rw-r--r--cmake/QtInternalTargets.cmake11
1 files changed, 2 insertions, 9 deletions
diff --git a/cmake/QtInternalTargets.cmake b/cmake/QtInternalTargets.cmake
index 72e6b6ab9a..e2eee5b89e 100644
--- a/cmake/QtInternalTargets.cmake
+++ b/cmake/QtInternalTargets.cmake
@@ -73,10 +73,7 @@ function(qt_internal_set_warnings_are_errors_flags target)
endfunction()
# The function adds a global 'definition' to the platform internal targets and the target
-# property-based switch to disable the definition. The following command disables the definition for
-# a specific target:
-# set_target_properties(<target> PROPERTIES QT_INTERNAL_UNDEF_<definition> TRUE)
-# where 'QT_INTERNAL_UNDEF_<definition>' might be customized using the UNDEF_PROPERTY_NAME option.
+# property-based switch to disable the definition.
# Arguments:
# VALUE optional value that the definition will take.
# SCOPE the list of scopes the definition needs to be set for. If the SCOPE is not specified the
@@ -87,10 +84,9 @@ endfunction()
# TOOL - set the definition for all Qt tools
# APP - set the definition for all Qt applications
# TODO: Add a tests specific platform target and the definition scope for it.
-# UNDEF_PROPERTY_NAME customizes the name of the target property to avoid adding the definition.
function(qt_internal_add_global_definition definition)
set(optional_args)
- set(single_value_args VALUE UNDEF_PROPERTY_NAME)
+ set(single_value_args VALUE)
set(multi_value_args SCOPE)
cmake_parse_arguments(args
"${optional_args}"
@@ -105,9 +101,6 @@ function(qt_internal_add_global_definition definition)
set(scope_APP PlatformAppInternal)
set(undef_property_name "QT_INTERNAL_UNDEF_${definition}")
- if(DEFINED arg_UNDEF_PROPERTY_NAME)
- set(undef_property_name "${arg_UNDEF_PROPERTY_NAME}")
- endif()
if(DEFINED arg_VALUE)
set(definition "${definition}=${arg_VALUE}")