diff options
author | Slávek Banko <slavek.banko@axis.cz> | 2018-12-20 18:46:01 +0100 |
---|---|---|
committer | Slávek Banko <slavek.banko@axis.cz> | 2018-12-20 18:46:01 +0100 |
commit | 9fed4e832edb35b2d169172a8380453aac98b143 (patch) | |
tree | e1f9a07b060fd9a077abeff122b556715ca61fd2 /CMakeLists.txt | |
parent | 269d880860c7d34cb937400d8bfa6d6f61ce0473 (diff) | |
download | k3b-i18n-9fed4e832edb35b2d169172a8380453aac98b143.tar.gz k3b-i18n-9fed4e832edb35b2d169172a8380453aac98b143.zip |
Add translation templates.
Modify CMake rules for translations
to make them independent of languages.
Signed-off-by: Slávek Banko <slavek.banko@axis.cz>
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 4686c49..1efbabf 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -57,7 +57,19 @@ option( BUILD_DOC "Build documentation" ON ) option( BUILD_MESSAGES "Build message and GUI translation" ON ) +###### build translations for all languages ##### + +if( BUILD_MESSAGES ) + file( GLOB_RECURSE po_files RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} */messages/*.po ) + + foreach( _po ${po_files} ) + string( REPLACE "/" ";" _path "${_po}" ) + list( GET _path 0 _lang ) + tde_create_translation( FILES ${_po} LANG ${_lang} ) + endforeach( ) +endif( ) + + ###### subdirectories ########################### tde_auto_add_subdirectories( ) - |