mirror of
https://github.com/minetest/minetest.git
synced 2024-11-27 10:03:45 +01:00
Move unsupported language list into a separate file (#13865)
This commit is contained in:
parent
8db4381304
commit
c60d971bc4
@ -56,6 +56,9 @@ task prepareAssets() {
|
|||||||
def projRoot = rootDir.parent
|
def projRoot = rootDir.parent
|
||||||
def gameToCopy = "minetest_game"
|
def gameToCopy = "minetest_game"
|
||||||
|
|
||||||
|
// See issue #4638
|
||||||
|
def unsupportedLanguages = new File("${projRoot}/src/unsupported_language_list.txt").text.readLines()
|
||||||
|
|
||||||
doFirst {
|
doFirst {
|
||||||
logger.lifecycle('Preparing assets at {}', assetsFolder)
|
logger.lifecycle('Preparing assets at {}', assetsFolder)
|
||||||
}
|
}
|
||||||
@ -86,7 +89,9 @@ task prepareAssets() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// compile translations
|
// compile translations
|
||||||
fileTree("${projRoot}/po").include("**/*.po").forEach { poFile ->
|
fileTree("${projRoot}/po").include("**/*.po").grep {
|
||||||
|
it.parentFile.name !in unsupportedLanguages
|
||||||
|
}.forEach { poFile ->
|
||||||
def moPath = "${assetsFolder}/locale/${poFile.parentFile.name}/LC_MESSAGES/"
|
def moPath = "${assetsFolder}/locale/${poFile.parentFile.name}/LC_MESSAGES/"
|
||||||
file(moPath).mkdirs()
|
file(moPath).mkdirs()
|
||||||
exec {
|
exec {
|
||||||
|
@ -155,6 +155,7 @@ end
|
|||||||
|
|
||||||
-- These must not be translated, as they need to show in the local
|
-- These must not be translated, as they need to show in the local
|
||||||
-- language no matter the user's current language.
|
-- language no matter the user's current language.
|
||||||
|
-- This list must be kept in sync with src/unsupported_language_list.txt.
|
||||||
get_setting_info("language").option_labels = {
|
get_setting_info("language").option_labels = {
|
||||||
[""] = fgettext_ne("(Use system language)"),
|
[""] = fgettext_ne("(Use system language)"),
|
||||||
--ar = " [ar]", blacklisted
|
--ar = " [ar]", blacklisted
|
||||||
|
@ -660,17 +660,9 @@ if(BUILD_SERVER)
|
|||||||
endif()
|
endif()
|
||||||
endif(BUILD_SERVER)
|
endif(BUILD_SERVER)
|
||||||
|
|
||||||
# Blacklisted locales that don't work.
|
# See issue #4638
|
||||||
# see issue #4638
|
FILE(READ "${CMAKE_SOURCE_DIR}/src/unsupported_language_list.txt" GETTEXT_BLACKLISTED_LOCALES)
|
||||||
set(GETTEXT_BLACKLISTED_LOCALES
|
STRING(REGEX REPLACE "\n" ";" GETTEXT_BLACKLISTED_LOCALES "${GETTEXT_BLACKLISTED_LOCALES}")
|
||||||
ar
|
|
||||||
dv
|
|
||||||
he
|
|
||||||
hi
|
|
||||||
kn
|
|
||||||
ms_Arab
|
|
||||||
th
|
|
||||||
)
|
|
||||||
|
|
||||||
option(APPLY_LOCALE_BLACKLIST "Use a blacklist to avoid known broken locales" TRUE)
|
option(APPLY_LOCALE_BLACKLIST "Use a blacklist to avoid known broken locales" TRUE)
|
||||||
|
|
||||||
|
8
src/unsupported_language_list.txt
Normal file
8
src/unsupported_language_list.txt
Normal file
@ -0,0 +1,8 @@
|
|||||||
|
List of languages that are not supported. See issue #4638.
|
||||||
|
ar
|
||||||
|
dv
|
||||||
|
he
|
||||||
|
hi
|
||||||
|
kn
|
||||||
|
ms_Arab
|
||||||
|
th
|
Loading…
Reference in New Issue
Block a user