1
0
mirror of https://github.com/clementine-player/Clementine synced 2024-12-14 02:14:21 +01:00

Build the list of languages dynamically from the list of .po files.

Update issue #902
Status: Fixed

Thanks for the patch!
This commit is contained in:
David Sansome 2010-10-23 13:46:45 +00:00
parent 1967e0e53c
commit 034c1b58f9

View File

@ -387,41 +387,12 @@ set(RESOURCES
set(LINGUAS "All" CACHE STRING "A space-seperated list of translations to compile in to Clementine, or \"None\".")
if (LINGUAS STREQUAL "All")
set (LANGUAGES
ar
bg
ca
cs
da
de
el
en_CA
en_GB
es
fi
fr
gl
hu
it
kk
lt
nb
nl
oc
pl
pt
pt_BR
ro
ru
sk
sl
sr
sv
tr
uk
zh_CN
zh_TW
)
# build LANGUAGES from all existing .po files
file(GLOB pofiles translations/*.po)
foreach(pofile ${pofiles})
get_filename_component(lang ${pofile} NAME_WE)
list(APPEND LANGUAGES ${lang})
endforeach(pofile)
else (LINGUAS STREQUAL "All")
if (NOT LINGUAS OR LINGUAS STREQUAL "None")
set (LANGUAGES "")