[rkward] i18n: Avoid creating empty directories for purged translations.
Thomas Friedrichsmeier
null at kde.org
Tue Apr 10 19:37:52 UTC 2018
Git commit 161f8230c5fd5d947981013ef7393827441dcd25 by Thomas Friedrichsmeier.
Committed on 10/04/2018 at 19:37.
Pushed by tfry into branch 'master'.
Avoid creating empty directories for purged translations.
M +7 -5 i18n/CMakeLists.txt
https://commits.kde.org/rkward/161f8230c5fd5d947981013ef7393827441dcd25
diff --git a/i18n/CMakeLists.txt b/i18n/CMakeLists.txt
index 1eeaba60..5633a1e7 100644
--- a/i18n/CMakeLists.txt
+++ b/i18n/CMakeLists.txt
@@ -21,11 +21,13 @@ MACRO(RKHandlePO _PO_FILES)
DEPENDS ${_poFile})
LIST(APPEND active_translations ${_stampFile})
- IF(${_poid} STREQUAL "rkward")
- INSTALL(FILES ${_gmoFile} DESTINATION ${LOCALE_INSTALL_DIR}/${_lang}/LC_MESSAGES/ RENAME rkward.mo OPTIONAL)
- ELSE(${_poid} STREQUAL "rkward")
- INSTALL(FILES ${_gmoFile} DESTINATION ${DATA_INSTALL_DIR}/rkward/po/${_lang}/LC_MESSAGES/ RENAME ${_poid}.mo OPTIONAL)
- ENDIF(${_poid} STREQUAL "rkward")
+ IF(EXISTS ${_gmoFile})
+ IF(${_poid} STREQUAL "rkward")
+ INSTALL(FILES ${_gmoFile} DESTINATION ${LOCALE_INSTALL_DIR}/${_lang}/LC_MESSAGES/ RENAME rkward.mo OPTIONAL)
+ ELSE(${_poid} STREQUAL "rkward")
+ INSTALL(FILES ${_gmoFile} DESTINATION ${DATA_INSTALL_DIR}/rkward/po/${_lang}/LC_MESSAGES/ RENAME ${_poid}.mo OPTIONAL)
+ ENDIF(${_poid} STREQUAL "rkward")
+ ENDIF(EXISTS ${_gmoFile})
ENDFOREACH(_poFile ${_PO_FILES})
ENDMACRO(RKHandlePO)
More information about the rkward-tracker
mailing list