1
0
Fork 0
mirror of https://github.com/luanti-org/luanti.git synced 2025-06-27 16:36:03 +00:00

Clean up gettext initialization

This commit is contained in:
sfan5 2023-12-19 22:01:28 +01:00
parent 93c2aff2cf
commit b8dc349099
3 changed files with 83 additions and 82 deletions

View file

@ -40,7 +40,9 @@ with this program; if not, write to the Free Software Foundation, Inc.,
extern int main(int argc, char *argv[]);
namespace porting {
void cleanupAndroid(); // used here
// used here:
void cleanupAndroid();
std::string getLanguageAndroid();
bool setSystemPaths(); // used in porting.cpp
}
@ -101,6 +103,11 @@ void osSpecificInit()
"porting::initAndroid unable to find Java native activity class" <<
std::endl;
// Set default language
auto lang = getLanguageAndroid();
unsetenv("LANGUAGE");
setenv("LANG", lang.c_str(), 1);
#ifdef GPROF
// in the start-up code
warningstream << "Initializing GPROF profiler" << std::endl;