summaryrefslogtreecommitdiffstats
path: root/src/corelib/Qt6AndroidMacros.cmake
diff options
context:
space:
mode:
authorCraig Scott <craig.scott@qt.io>2021-08-31 15:56:00 +1000
committerCraig Scott <craig.scott@qt.io>2021-08-31 17:05:15 +1000
commit08180e76e6116f0ef66476ca00b2b676b3aa50da (patch)
treecb661ebcfd916457064982c0346deef661aa8570 /src/corelib/Qt6AndroidMacros.cmake
parentd54d91c0ad42ec831d3b4e01f66b6bd61010c8d6 (diff)
Ensure versionless wrappers do not introduce a new variable scope
Using function instead of macro prevented the wrappers from being able to pass back any variables set in the wrapped function. In some cases, these variables were being explicitly passed back to the caller, but that isn't needed if you just make each wrapper a macro. This also makes things more future-proof because any newly introduced output variables will work without having to update the wrappers. Task-number: QTBUG-96121 Pick-to: 6.2 Change-Id: Ic4486de668694c06b47e466587b2cdcb969ea047 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
Diffstat (limited to 'src/corelib/Qt6AndroidMacros.cmake')
-rw-r--r--src/corelib/Qt6AndroidMacros.cmake12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/corelib/Qt6AndroidMacros.cmake b/src/corelib/Qt6AndroidMacros.cmake
index c5f04c49bc..9b68d57001 100644
--- a/src/corelib/Qt6AndroidMacros.cmake
+++ b/src/corelib/Qt6AndroidMacros.cmake
@@ -262,9 +262,9 @@ function(qt6_android_generate_deployment_settings target)
endfunction()
if(NOT QT_NO_CREATE_VERSIONLESS_FUNCTIONS)
- function(qt_android_generate_deployment_settings)
+ macro(qt_android_generate_deployment_settings)
qt6_android_generate_deployment_settings(${ARGV})
- endfunction()
+ endmacro()
endif()
function(qt6_android_apply_arch_suffix target)
@@ -277,9 +277,9 @@ function(qt6_android_apply_arch_suffix target)
endfunction()
if(NOT QT_NO_CREATE_VERSIONLESS_FUNCTIONS)
- function(qt_android_apply_arch_suffix)
+ macro(qt_android_apply_arch_suffix)
qt6_android_apply_arch_suffix(${ARGV})
- endfunction()
+ endmacro()
endif()
# Add custom target to package the APK
@@ -397,7 +397,7 @@ function(_qt_internal_create_global_apk_all_target_if_needed)
endfunction()
if(NOT QT_NO_CREATE_VERSIONLESS_FUNCTIONS)
- function(qt_android_add_apk_target)
+ macro(qt_android_add_apk_target)
qt6_android_add_apk_target(${ARGV})
- endfunction()
+ endmacro()
endif()