Subject: Re: Return from nl_langinfo(CODESET)--any standard?
To: None <tech-userlevel@netbsd.org>
From: James K. Lowden <jklowden@schemamania.org>
List: tech-userlevel
Date: 01/25/2003 16:46:32
On 24 Jan 2003 23:04:41 +0100, Klaus Klein <kleink@reziprozitaet.de>
wrote:
> Dave Huang <khym@azeotrope.org> writes:
> 
> > Yesterday, I ran into a program that assumes that the output of
> > nl_langinfo(CODESET) is a name that (GNU) libiconv recognizes. This
> > doesn't seem like an unreasonable assumption to me [...]
> > 
> > So, is there any reason why our nl_langinfo() doesn't return an 
> > "official" name, such as one from 
> > http://www.iana.org/assignments/character-sets ?  
> 
> This would be one of the "so many to choose from!" issues. :-)
> 
> While there's GNU supporting IANA names, there is also a lot of prior
> art in SVR4-originated environments

The things you learn reading tech-userlevel!  

It might be worthwhile to point out that Gnu's IANA support was well
considered, cf. /usr/pkgsrc/converters/libiconv/work/libiconv-1.7/NOTES. 
Also the IANA registry is relied on by the XML standard,
http://www.w3.org/International/O-charset.html.  That means Gnu libiconv
works hand-in-glove with XML, a very powerful and useful combination.  

I'd be very interested to hear what's happening with NetBSD's locale
support.  I have a direct interest: I maintain a database library in which
we're improving our locale support, and I can't set up an ISO-8859-15
environment on my favorite operating system.  

I don't see how we can go wrong using IANA names.  

--jkl

> [1] http://ftp.x.org/pub/R6.6/xc/registry
> [2] ftp://ftp.opengroup.org/pub/code_set_registry
> [3] http://std.dkuug.dk/cultreg/
> [4] http://citrus.bsdclub.org/index.html