summaryrefslogtreecommitdiffhomepage
path: root/cmake/opentrack-install.cmake
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2016-12-16 12:48:12 +0100
committerStanislaw Halik <sthalik@misaki.pl>2016-12-16 12:48:12 +0100
commitd564786057c62dce58ecf9ebd9726310fc3ab598 (patch)
tree62da93c6cf8576f46eb3604c621a6003721c58c0 /cmake/opentrack-install.cmake
parent8cb5e8effdd7981449c9f00891748afd1237c175 (diff)
cmake: fix mrproper -> install without regen translations enabled
Diffstat (limited to 'cmake/opentrack-install.cmake')
-rw-r--r--cmake/opentrack-install.cmake11
1 files changed, 6 insertions, 5 deletions
diff --git a/cmake/opentrack-install.cmake b/cmake/opentrack-install.cmake
index 3406007b..56067f1b 100644
--- a/cmake/opentrack-install.cmake
+++ b/cmake/opentrack-install.cmake
@@ -56,7 +56,7 @@ function(merge_translations)
get_property(modules GLOBAL PROPERTY opentrack-all-modules)
foreach(i ${opentrack-all-translations})
- get_property(ts GLOBAL PROPERTY opentrack-${i}-ts)
+ get_property(ts GLOBAL PROPERTY "opentrack-ts-${i}")
set(qm-output "${CMAKE_BINARY_DIR}/${i}.qm")
@@ -65,15 +65,16 @@ function(merge_translations)
list(APPEND deps "i18n-module-${k}")
endforeach()
- if(NOT "${ts}" STREQUAL "")
+ if(NOT ts STREQUAL "")
add_custom_target(i18n-lang-${i}
COMMAND "${Qt5_DIR}/../../../bin/lrelease" -nounfinished -silent ${ts} -qm "${qm-output}"
DEPENDS ${deps})
+ list(APPEND all-deps "i18n-lang-${i}")
+ install(FILES "${qm-output}" DESTINATION "${opentrack-i18n-pfx}" RENAME "${i}.qm" ${opentrack-perms})
else()
- add_custom_target(i18n-lang-${i} DEPENDS ${deps})
+ #add_custom_target(i18n-lang-${i} DEPENDS ${deps})
+ message(FATAL_ERROR "build logic error: no translations for language ${i}")
endif()
- list(APPEND all-deps "i18n-lang-${i}")
- install(FILES "${qm-output}" DESTINATION "${opentrack-i18n-pfx}" RENAME "${i}.qm" ${opentrack-perms})
endforeach()
add_custom_target(i18n ALL DEPENDS ${all-deps})
endfunction()