On Monday 30 January 2006 01:44, Jacob Meuser wrote:
> On Mon, Jan 30, 2006 at 02:23:55AM +0200, Antti Harri wrote:
> > On Sun, 29 Jan 2006, Jacob Meuser wrote:
> > >http://marc.theaimsgroup.com/l=openbsd-ports&m=113384927704993&w=2
> >
> > For the archives here's the correct URL:
> > http://marc.theaimsgroup.com/?l=openbsd-ports&m=113384927704993&w=2
>
> oops! thanks.
>
> > I wrote a simple patch that makes Irssi use locale_charset()
> > instead of nl_langinfo(). At least it made the glib-warning
> > to go away (in Irssi term_charset was set to ASCII) so if this is the
> > best way to fix it
>
> I think this is the only solution for this problem.
Thanks for the link. And basing on that, I am right now trying to compile
irssi with the following patch, hopefully that will help. Shall see in the
morning, now sleep while it compiles ;)
<~/irssi>$ cat patches/patch-src_fe-common_core_fe-common-core_c
$OpenBSD$
--- src/fe-common/core/fe-common-core.c.orig Fri Feb 3 02:41:33 2006
+++ src/fe-common/core/fe-common-core.c Fri Feb 3 02:47:45 2006
@@ -25,8 +25,8 @@
#include "levels.h"
#include "settings.h"
#include "irssi-version.h"
-#ifdef HAVE_NL_LANGINFO
-# include <langinfo.h>
+#ifdef USE_LIBICONV
+#include <localcharset.h>
#endif
#include "servers.h"
@@ -174,10 +174,12 @@ void fe_common_core_init(void)
settings_add_bool("lookandfeel", "use_status_window", TRUE);
settings_add_bool("lookandfeel", "use_msgs_window", FALSE);
-#if defined (HAVE_NL_LANGINFO) && defined(CODESET)
- settings_add_str("lookandfeel", "term_charset",
- *nl_langinfo(CODESET) != '\0' ?
- nl_langinfo(CODESET) : "ISO8859-1");
+
+#ifdef USE_LIBICONV
+ settings_add_str("lookandfeel", "term_charset",
+ *locale_charset() != '\0' ?
+ locale_charset() : "ISO8859-1");
+
#else
settings_add_str("lookandfeel", "term_charset", "ISO8859-1");
#endif
--
viq