summaryrefslogtreecommitdiffhomepage
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
parent8cb5e8effdd7981449c9f00891748afd1237c175 (diff)
cmake: fix mrproper -> install without regen translations enabled
-rw-r--r--cmake/opentrack-boilerplate.cmake6
-rw-r--r--cmake/opentrack-hier.cmake1
-rw-r--r--cmake/opentrack-install.cmake11
-rw-r--r--cmake/opentrack-qt.cmake1
4 files changed, 9 insertions, 10 deletions
diff --git a/cmake/opentrack-boilerplate.cmake b/cmake/opentrack-boilerplate.cmake
index 9ca382e8..9ea00238 100644
--- a/cmake/opentrack-boilerplate.cmake
+++ b/cmake/opentrack-boilerplate.cmake
@@ -222,10 +222,10 @@ function(opentrack_boilerplate n)
set(t "${CMAKE_CURRENT_SOURCE_DIR}/lang/${i}.ts")
if(SDK_REGEN_TRANSLATIONS OR NOT EXISTS "${t}")
list(APPEND langs "${t}")
- get_property(tt GLOBAL PROPERTY opentrack-${i}-ts)
- set(tt ${tt} ${t})
- set_property(GLOBAL PROPERTY opentrack-${i}-ts ${tt})
endif()
+ get_property(tt GLOBAL PROPERTY "opentrack-ts-${i}")
+ list(APPEND tt "${t}")
+ set_property(GLOBAL PROPERTY "opentrack-ts-${i}" "${tt}")
endforeach()
get_property(modules GLOBAL PROPERTY opentrack-all-modules)
diff --git a/cmake/opentrack-hier.cmake b/cmake/opentrack-hier.cmake
index 8ba62830..5c58935c 100644
--- a/cmake/opentrack-hier.cmake
+++ b/cmake/opentrack-hier.cmake
@@ -59,5 +59,4 @@ if(NOT opentrack-hier-included)
elseif(WIN32)
set(opentrack-binary-suffix ".exe")
endif()
-
endif() # include guard
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()
diff --git a/cmake/opentrack-qt.cmake b/cmake/opentrack-qt.cmake
index c6ab2673..38ef8b94 100644
--- a/cmake/opentrack-qt.cmake
+++ b/cmake/opentrack-qt.cmake
@@ -14,7 +14,6 @@ endif()
string(FIND "${CMAKE_GENERATOR}" "Visual Studio " is-msvc)
# on .sln generator we have no editbin path ready
-
if(MSVC AND NOT is-msvc EQUAL 0)
install(CODE "
foreach(i Qt5Core Qt5Gui Qt5Network Qt5SerialPort Qt5Widgets platforms/qwindows)