diff options
author | Li Xinwei <1326710505@qq.com> | 2020-11-18 21:40:56 +0800 |
---|---|---|
committer | Qt Cherry-pick Bot <cherrypick_bot@qt-project.org> | 2020-11-21 19:34:32 +0000 |
commit | ebacea6cd6ce75f468eeaf446f5b691da9bc2c6a (patch) | |
tree | 4c472b4c0d7756ab5b14d7624ce3cc993c7e927a | |
parent | 5d45d89fec1d5d43657758a8152a203d095b8d39 (diff) | |
download | qttools-ebacea6cd6ce75f468eeaf446f5b691da9bc2c6a.tar.gz |
windeployqt CMake: add target description and use qt_internal_add_tool()
Compared to windeployqt.pro and .prev_CMakeLists.txt, the target
description is missing in CMakeLists.txt.
Using qt_internal_add_tool() instead of qt_add_executable() can exclude
the Debug build of windeployqt in multi-config build for CMake 3.19.0.
Change-Id: I54692875494b2d9e7de7826d3758fe78d10dbddf
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
(cherry picked from commit 6ea90064cb46470f8f5e3f12e1337ca4af4ee304)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
-rw-r--r-- | src/windeployqt/CMakeLists.txt | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/src/windeployqt/CMakeLists.txt b/src/windeployqt/CMakeLists.txt index 9c2cb7142..7143509b2 100644 --- a/src/windeployqt/CMakeLists.txt +++ b/src/windeployqt/CMakeLists.txt @@ -4,8 +4,11 @@ ## windeployqt Tool: ##################################################################### -qt_internal_add_executable(windeployqt # special case - #BOOTSTRAP # special case remove +qt_get_tool_target_name(target_name windeployqt) +qt_internal_add_tool(${target_name} + # BOOTSTRAP # special case remove + TOOLS_TARGET "Tools" # special case + TARGET_DESCRIPTION "Qt Windows Deployment Tool" SOURCES ../shared/winutils/elfreader.cpp ../shared/winutils/elfreader.h ../shared/winutils/qmlutils.cpp ../shared/winutils/qmlutils.h @@ -31,12 +34,12 @@ qt_internal_add_executable(windeployqt # special case ## Scopes: ##################################################################### -qt_internal_extend_target(windeployqt CONDITION WIN32 # special case +qt_internal_extend_target(${target_name} CONDITION WIN32 PUBLIC_LIBRARIES shlwapi ) -qt_internal_extend_target(windeployqt CONDITION QT_FEATURE_relocatable # special case +qt_internal_extend_target(${target_name} CONDITION QT_FEATURE_relocatable DEFINES QT_RELOCATABLE ) |