[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Wesnoth-cvs-commits] wesnoth/src filesystem.cpp language.cpp
From: |
David White |
Subject: |
[Wesnoth-cvs-commits] wesnoth/src filesystem.cpp language.cpp |
Date: |
Fri, 10 Sep 2004 23:28:47 -0400 |
CVSROOT: /cvsroot/wesnoth
Module name: wesnoth
Branch:
Changes by: David White <address@hidden> 04/09/11 03:23:21
Modified files:
src : filesystem.cpp language.cpp
Log message:
added patch to make gettext work with OSX
CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/wesnoth/wesnoth/src/filesystem.cpp.diff?tr1=1.42&tr2=1.43&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/wesnoth/wesnoth/src/language.cpp.diff?tr1=1.43&tr2=1.44&r1=text&r2=text
Patches:
Index: wesnoth/src/filesystem.cpp
diff -u wesnoth/src/filesystem.cpp:1.42 wesnoth/src/filesystem.cpp:1.43
--- wesnoth/src/filesystem.cpp:1.42 Mon Sep 6 20:50:48 2004
+++ wesnoth/src/filesystem.cpp Sat Sep 11 03:23:21 2004
@@ -1,4 +1,4 @@
-/* $Id: filesystem.cpp,v 1.42 2004/09/06 20:50:48 Sirp Exp $ */
+/* $Id: filesystem.cpp,v 1.43 2004/09/11 03:23:21 Sirp Exp $ */
/*
Copyright (C) 2003 by David White <address@hidden>
Part of the Battle for Wesnoth Project http://wesnoth.whitevine.net
@@ -185,6 +185,11 @@
std::string get_intl_dir()
{
+
+#ifdef __APPLE__
+ return get_cwd() + "/messages";
+#endif
+
std::string res;
#if HAS_RELATIVE_LOCALEDIR
res = game_config::path + "/" LOCALEDIR;
Index: wesnoth/src/language.cpp
diff -u wesnoth/src/language.cpp:1.43 wesnoth/src/language.cpp:1.44
--- wesnoth/src/language.cpp:1.43 Thu Sep 9 22:39:02 2004
+++ wesnoth/src/language.cpp Sat Sep 11 03:23:21 2004
@@ -1,4 +1,4 @@
-/* $Id: language.cpp,v 1.43 2004/09/09 22:39:02 ydirson Exp $ */
+/* $Id: language.cpp,v 1.44 2004/09/11 03:23:21 Sirp Exp $ */
/*
Copyright (C) 2003 by David White <address@hidden>
Part of the Battle for Wesnoth Project http://wesnoth.whitevine.net
@@ -109,11 +109,16 @@
// problems, like the MacOS-X ones.
char* wesnoth_setlocale(int category, const char *locale)
{
- if (setenv ("LANG", locale, 1) == -1)
+ if(setenv ("LANG", locale, 1) == -1)
std::cerr << "setenv LANG failed: " << strerror(errno);
- if (setenv ("LC_ALL", locale, 1) == -1)
+ if(setenv ("LC_ALL", locale, 1) == -1)
std::cerr << "setenv LC_ALL failed: " << strerror(errno);
+ #ifdef __APPLE__
+ if(setenv ("LANGUAGE", locale, 1) == -1)
+ std::cerr << "setenv LANGUAGE failed: " << strerror(errno);
+ #endif
+
char* res = setlocale (category, locale);
if (res == NULL)
std::cerr << "WARNING: setlocale() failed for "
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Wesnoth-cvs-commits] wesnoth/src filesystem.cpp language.cpp,
David White <=