nixpkgs/pkgs/games/cataclysm-dda/patches/fix_locale_dir_git.patch
Mitsuhiro Nakamura d77ce49c75 cataclysm-dda{,-git}: fix locale directory
PREFIX/share/locale should be searched for translations not only on Linux.
2018-01-22 22:37:02 +09:00

21 lines
650 B
Diff

diff --git a/src/translations.cpp b/src/translations.cpp
index 3a86291..e6c5f84 100644
--- a/src/translations.cpp
+++ b/src/translations.cpp
@@ -176,15 +176,11 @@ void set_language()
// Step 2. Bind to gettext domain.
std::string locale_dir;
-#if (defined __linux__ || (defined MACOSX && !defined TILES))
if( !FILENAMES["base_path"].empty() ) {
locale_dir = FILENAMES["base_path"] + "share/locale";
} else {
locale_dir = "lang/mo";
}
-#else
- locale_dir = "lang/mo";
-#endif // __linux__
const char *locale_dir_char = locale_dir.c_str();
bindtextdomain( "cataclysm-dda", locale_dir_char );