diff options
author | Slávek Banko <slavek.banko@axis.cz> | 2020-05-03 18:43:01 +0200 |
---|---|---|
committer | Slávek Banko <slavek.banko@axis.cz> | 2020-05-03 18:43:01 +0200 |
commit | 58a301e1eb83e36f853c31173364f6e0c973f45c (patch) | |
tree | bef555c29cadcf7641e0c60525a66267240cfd56 /doc | |
parent | 60ad25eef1d7814beb9f738e55822175bcef216a (diff) | |
download | tdeio-gopher-58a301e1eb83e36f853c31173364f6e0c973f45c.tar.gz tdeio-gopher-58a301e1eb83e36f853c31173364f6e0c973f45c.zip |
Move translations to a new directory layout.
Add support for LINGUAS for listing translations to install.
Signed-off-by: Slávek Banko <slavek.banko@axis.cz>
Diffstat (limited to 'doc')
-rw-r--r-- | doc/CMakeLists.txt | 24 |
1 files changed, 13 insertions, 11 deletions
diff --git a/doc/CMakeLists.txt b/doc/CMakeLists.txt index a8b8de4..70d6348 100644 --- a/doc/CMakeLists.txt +++ b/doc/CMakeLists.txt @@ -1,12 +1,14 @@ -################################################# -# -# (C) 2010-2011 Serghei Amelian -# serghei (DOT) amelian (AT) gmail.com -# -# Improvements and feedback are welcome -# -# This file is released under GPL >= 2 -# -################################################# +file( GLOB _dirs RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} * ) +string( REGEX REPLACE "[ \r\n\t]+" ";" _linguas "$ENV{LINGUAS}" ) -tde_auto_add_subdirectories() +foreach( _dir ${_dirs} ) + if( IS_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/${_dir} AND + EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/${_dir}/CMakeLists.txt ) + if( "${_dir}" STREQUAL "en" OR + "${_dir}" STREQUAL "man" OR + "${_linguas}" MATCHES "^;*$" OR + ";${_linguas};" MATCHES ";${_dir};" ) + add_subdirectory( ${_dir} ) + endif( ) + endif() +endforeach() |