aboutsummaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
authorNicolás Alvarez <nicolas.alvarez@gmail.com>2014-04-23 13:07:26 -0300
committerNicolás Alvarez <nicolas.alvarez@gmail.com>2014-04-23 13:07:26 -0300
commitb8b7630bd5e67aa4a85c020d869531e443b805db (patch)
treee9c2fd616889ff9fb0889eea993c104e02a74815 /modules
parente7ca63c7c5a94279a284bbdcdd14e8c6c5597267 (diff)
downloadextra-cmake-modules-b8b7630bd5e67aa4a85c020d869531e443b805db.tar.gz
extra-cmake-modules-b8b7630bd5e67aa4a85c020d869531e443b805db.tar.bz2
Only search for qttools if ECM_CREATE_QM_FROM_PO_FILES is called.
This means frameworks will only depend on qttools if you have a po directory when building them. Approved by agateau and alexmerry on IRC.
Diffstat (limited to 'modules')
-rw-r--r--modules/ECMCreateQmFromPoFiles.cmake8
1 files changed, 4 insertions, 4 deletions
diff --git a/modules/ECMCreateQmFromPoFiles.cmake b/modules/ECMCreateQmFromPoFiles.cmake
index f331460d..7457fc51 100644
--- a/modules/ECMCreateQmFromPoFiles.cmake
+++ b/modules/ECMCreateQmFromPoFiles.cmake
@@ -79,10 +79,6 @@
# (To distribute this file outside of extra-cmake-modules, substitute the full
# License text for the above reference.)
-# This gives us Qt5::lrelease and Qt5::lupdate but unfortunately no Qt5::lconvert
-# See https://bugreports.qt-project.org/browse/QTBUG-37937
-find_package(Qt5LinguistTools CONFIG REQUIRED)
-
# Stolen from FindGettext.cmake
function(_ECM_QM_GET_UNIQUE_TARGET_NAME _name _unique_name)
set(propertyName "_ECM_QM_UNIQUE_COUNTER_${_name}")
@@ -162,6 +158,10 @@ function(ECM_CREATE_QM_LOADER out_var catalog_name)
endfunction()
function(ECM_CREATE_QM_FROM_PO_FILES)
+ # This gives us Qt5::lrelease and Qt5::lupdate but unfortunately no Qt5::lconvert
+ # See https://bugreports.qt-project.org/browse/QTBUG-37937
+ find_package(Qt5LinguistTools CONFIG REQUIRED)
+
foreach (arg ${ARGN})
if (arg STREQUAL "PO_DIR")
_ecm_create_qm_from_po_files_legacy(${ARGN})