From a34958e578c6165e2b28ec9144ca0ed51e183296 Mon Sep 17 00:00:00 2001 From: Andrey Astafyev Date: Fri, 19 Jul 2019 11:08:14 +0300 Subject: [PATCH] =?UTF-8?q?=D0=A3=D0=B1=D1=80=D0=B0=D0=BD=20=D0=BF=D0=B0?= =?UTF-8?q?=D1=80=D0=B0=D0=BC=D0=B5=D1=82=D1=80=20"=D0=9F=D1=83=D1=82?= =?UTF-8?q?=D1=8C=20=D0=BA=20=D0=B8=D1=81=D1=85=D0=BE=D0=B4=D0=BD=D0=B8?= =?UTF-8?q?=D0=BA=D0=B0=D0=BC"?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CMLibQtTranslation.cmake | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/CMLibQtTranslation.cmake b/CMLibQtTranslation.cmake index 5fcb863..e174416 100644 --- a/CMLibQtTranslation.cmake +++ b/CMLibQtTranslation.cmake @@ -10,16 +10,10 @@ function(qt_translation) set(_ts_dir ${_QTTR_TS_DIR}) set(_languages ${_QTTR_LANGUAGES}) get_target_property(_sources ${_target} SOURCES) - get_target_property(_source_dir ${_target} SOURCE_DIR) set(L10N_QRC_BODY "") make_directory(${_ts_dir}) - set(_sources_list "") - foreach(_s ${_sources}) - list(APPEND _sources_list ${_source_dir}/${_s}) - endforeach() - foreach(_lang ${_languages}) set(_ts "${_target}_${_lang}.ts") set(_qm "${_target}_${_lang}.qm") @@ -28,8 +22,8 @@ function(qt_translation) string(APPEND L10N_QRC_BODY "${CMAKE_BINARY_DIR}/${_qm}\n") add_custom_target(${_target}_l10n_${_lang} - COMMAND ${Qt5_LUPDATE_EXECUTABLE} ${_sources_list} -ts ${_ts_dir}/${_ts} -target-language ${_lang} - DEPENDS ${_sources_list}) + COMMAND ${Qt5_LUPDATE_EXECUTABLE} ${_sources} -ts ${_ts_dir}/${_ts} -target-language ${_lang} + DEPENDS ${_sources}) if(NOT EXISTS "${_ts_dir}/${_ts}") add_custom_target(${_ts} DEPENDS ${_target}_l10n_${_lang}) @@ -40,7 +34,7 @@ function(qt_translation) add_custom_command(OUTPUT ${CMAKE_BINARY_DIR}/${_qm} COMMAND ${Qt5_LRELEASE_EXECUTABLE} ARGS ${_ts_dir}/${_ts} -qm ${CMAKE_BINARY_DIR}/${_qm} - DEPENDS ${_ts} ${_sources_list}) + DEPENDS ${_ts} ${_sources}) endforeach() configure_file(${CMLIB_MODULE_DIR}/qrc/l10n.qrc.in