diff options
| author | Alexandru Croitor <alexandru.croitor@qt.io> | 2021-04-08 13:32:26 +0200 |
|---|---|---|
| committer | Alexandru Croitor <alexandru.croitor@qt.io> | 2021-04-12 11:40:44 +0200 |
| commit | c1ac201f5c9905751eb35531f26311c8d291f9cc (patch) | |
| tree | 94d36510600f2d79ee112a624ebbd6095417e385 /cmake/QtPluginHelpers.cmake | |
| parent | b6dd5d7c3b6735ef0f50c7eb068727496bff4abf (diff) | |
CMake: Fix condition evaluation in plugin's DEFAULT_IF option
Expand the condition without an extra negation.
This fixes incorrect condition evaluation for conditions not enclosed
in parenthesis.
Pick-to: 6.1
Change-Id: I4923059b6b199676058091c23d51c9368daaebd0
Reviewed-by: Craig Scott <craig.scott@qt.io>
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
Diffstat (limited to 'cmake/QtPluginHelpers.cmake')
| -rw-r--r-- | cmake/QtPluginHelpers.cmake | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/cmake/QtPluginHelpers.cmake b/cmake/QtPluginHelpers.cmake index 5972d1419dc..a3a4c94a806 100644 --- a/cmake/QtPluginHelpers.cmake +++ b/cmake/QtPluginHelpers.cmake @@ -149,12 +149,12 @@ function(qt_internal_add_plugin target) set(_default_plugin 1) endif() - if (DEFINED arg_DEFAULT_IF) - if (NOT ${arg_DEFAULT_IF}) - set(_default_plugin 0) - else() - set(_default_plugin 1) - endif() + if(DEFINED arg_DEFAULT_IF) + if(${arg_DEFAULT_IF}) + set(_default_plugin 1) + else() + set(_default_plugin 0) + endif() endif() # Save the Qt module in the plug-in's properties and vice versa |
