diff options
author | Alexey Edelev <alexey.edelev@qt.io> | 2020-12-15 18:09:32 +0100 |
---|---|---|
committer | Alexey Edelev <alexey.edelev@qt.io> | 2020-12-21 13:41:13 +0100 |
commit | 56bdef94379479f27858dccc73a95614648735bb (patch) | |
tree | 3ad5f8f1a3fd2fc57486a42e01ce589f17e1c858 /cmake/QtPlatformAndroid.cmake | |
parent | 50f939bfe8bdd63beca4aff06cbf1b2be1677624 (diff) | |
download | qtbase-56bdef94379479f27858dccc73a95614648735bb.tar.gz |
CMake: Use host variables instead of hardcoded directories
'QT_HOST_PATH' indicates that we use crosscompilation toolchain
to build project. In this case 'Qt6Config.cmake' loads
'Qt6HostInfoConfig.cmake' from host QT_HOST_PATH, that defines
correct paths to host tools.
Replace hardcoded paths for host tools by paths recorded
in Qt6HostInfoConfig.cmake.
Correct conditions for QT_HOST_PATH, evaluate it explicitly as
string, but not as boolean expression.
Fixes: QTBUG-86557
Pick-to: 6.0
Change-Id: Ib52bbd32478051d019a932dcb1f735e2d4aacfbf
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
Diffstat (limited to 'cmake/QtPlatformAndroid.cmake')
-rw-r--r-- | cmake/QtPlatformAndroid.cmake | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/cmake/QtPlatformAndroid.cmake b/cmake/QtPlatformAndroid.cmake index 517b442873..1bca423d9e 100644 --- a/cmake/QtPlatformAndroid.cmake +++ b/cmake/QtPlatformAndroid.cmake @@ -127,8 +127,8 @@ define_property(TARGET # Returns test execution arguments for Android targets function(qt_internal_android_test_arguments target out_test_runner out_test_arguments) - set(${out_test_runner} "${QT_HOST_PATH}/bin/androidtestrunner" PARENT_SCOPE) - set(deployment_tool "${QT_HOST_PATH}/bin/androiddeployqt") + set(${out_test_runner} "${QT_HOST_PATH}/${QT${PROJECT_VERSION_MAJOR}_HOST_INFO_BINDIR}/androidtestrunner" PARENT_SCOPE) + set(deployment_tool "${QT_HOST_PATH}/${QT${PROJECT_VERSION_MAJOR}_HOST_INFO_BINDIR}/androiddeployqt") get_target_property(deployment_file ${target} QT_ANDROID_DEPLOYMENT_SETTINGS_FILE) if (NOT deployment_file) |