summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlexey Edelev <alexey.edelev@qt.io>2021-09-20 17:30:08 +0200
committerAlexey Edelev <alexey.edelev@qt.io>2021-09-21 16:05:22 +0200
commit68ad67b6faf6922c66ddafee0dc055666a73cddd (patch)
tree538b3abf343e33ab44577ad2906b6e98057c1739
parent080bbb9f8b8af9b31ceabffc2ff04edb316efb02 (diff)
Use only supported values when setting internal QT_FEATURE_ values
When setting QT_FEATURE_ values we need to convert the user-provided FEATURE_ values to the one that is supported by QT_FEATURE_. Pick-to: 6.2 Fixes: QTBUG-96300 Change-Id: Idd19fbf7f23f351a6c1cfdcedccfaaf6b0aa6e44 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
-rw-r--r--cmake/QtFeature.cmake6
1 files changed, 5 insertions, 1 deletions
diff --git a/cmake/QtFeature.cmake b/cmake/QtFeature.cmake
index fc2fb8f529..5ad96439b9 100644
--- a/cmake/QtFeature.cmake
+++ b/cmake/QtFeature.cmake
@@ -269,7 +269,11 @@ endfunction()
# Saves the final user value to QT_FEATURE_${feature}, after checking that the condition is met.
macro(qt_feature_check_and_save_internal_value
feature saved_user_value condition label conditionExpression)
- set(result "${saved_user_value}")
+ if(${saved_user_value})
+ set(result ON)
+ else()
+ set(result OFF)
+ endif()
if ((NOT condition) AND result)
_qt_internal_dump_expression_values(conditionDump "${conditionExpression}")