On Mon, 10 Sep 2001, Jungshik Shin wrote:
> > I know that it is OS dependent but how is it locale dependent?
>
>  At least under Solaris, it's locale-dependent. I don't know
> the details, but it seems like somehow Sun engineers found that it's
> better that way (in terms of efficiency or some other metrics....).

I talked to Sun i18n engineers about this and their primary concern was
binary backwards compatibility to how they did things before Unicode was
available. Instead of making wchar_t locale independent, which they feel
they can't do any more without breaking binary compatibility, they hope to
be able to convince everyone to use in the future only either UTF-8
locales, or the ...@ucs locales which use wchar_t = UCS, even though the
multibyte charset is not directly a UCS encoding.

You certainly can use under Solaris today every supported multi-byte
encoding with wchar_t = UCS, if only you restrict yourself to the ...@ucs
locales. I suggested to them to modify the header files, such that if the
user provides a compiler option -D__STDC_ISO_10646__, then a macro should
substitute setlocale with setlocale_ucsonly, which returns an error
message if the user tries to set one of the legacy locales that do not
have wchar_t = UCS.

Glibc didn't have this backwards compatibility concern, because UCS has
been long around before glibc got multi-byte support, so it was easily
possible to guarantee wchar_t = UCS for all locales here.

The really silly thing is that there are people currently (2001) working
on fresh all-new locale support for FreeBSD, and they do not (yet) plan to
keep wchar_t = UCS for all locales. I had a discussion with them, and I am
afraid, I have now to conclude that they are simply ignorant and full of
bizzare historic misconceptions about Unicode (they are roughly frozen at
the state of the discussion in the Japanese Unix community around 1993
before JIS X 0221 was published and everyone believed that the now mostly
forgotten TRON code would bring the salvation to the Japanese character
set chaos).

If you can, stick with glibc 2.2.

Markus

-- 
Markus G. Kuhn, Computer Laboratory, University of Cambridge, UK
Email: mkuhn at acm.org,  WWW: <http://www.cl.cam.ac.uk/~mgk25/>

-
Linux-UTF8:   i18n of Linux on all levels
Archive:      http://mail.nl.linux.org/linux-utf8/

Reply via email to