diff options
author | Stanislaw Halik <sthalik@misaki.pl> | 2017-08-10 10:45:49 +0200 |
---|---|---|
committer | Stanislaw Halik <sthalik@misaki.pl> | 2017-08-14 19:19:59 +0200 |
commit | 07f16d4ff648fee65cb3f7aaf313e9616179e9d0 (patch) | |
tree | d831af285081d56267b00d2cbce38c1628765fa4 /cmake/opentrack-boilerplate.cmake | |
parent | 70fa0b3f7e1ec4581e30127785fb6d59b89ec704 (diff) |
cmake: get lupdate/lrelease pathnames
cf. #669
Diffstat (limited to 'cmake/opentrack-boilerplate.cmake')
-rw-r--r-- | cmake/opentrack-boilerplate.cmake | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/cmake/opentrack-boilerplate.cmake b/cmake/opentrack-boilerplate.cmake index e93d2bfe..555e686d 100644 --- a/cmake/opentrack-boilerplate.cmake +++ b/cmake/opentrack-boilerplate.cmake @@ -111,18 +111,14 @@ endfunction() function(otr_i18n_for_target_directory n) set(k "opentrack-${n}") - if (LINUX) - set(LUPDATE_BIN "${Qt5_DIR}/../../../../bin/lupdate") - else() - set(LUPDATE_BIN "${Qt5_DIR}/../../../bin/lupdate") - endif() + get_property(lupdate-binary TARGET "${Qt5_LUPDATE_EXECUTABLE}" PROPERTY IMPORTED_LOCATION) foreach(i ${opentrack_all-translations}) set(t "${CMAKE_CURRENT_SOURCE_DIR}/lang/${i}.ts") if(NOT opentrack_disable-i18n-update) add_custom_command(OUTPUT "${t}" COMMAND ${CMAKE_COMMAND} -E make_directory "${CMAKE_CURRENT_SOURCE_DIR}/lang" - COMMAND ${LUPDATE_BIN} -silent -recursive -no-obsolete -locations relative . -ts "${t}" + COMMAND "${lupdate-binary}" -silent -recursive -no-obsolete -locations relative . -ts "${t}" WORKING_DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}" DEPENDS ${${k}-cc} ${${k}-hh} ${${k}-ui} ${${k}-rc} COMMENT "Running lupdate for ${n}/${i}") |