This is the mail archive of the libc-alpha@sources.redhat.com mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: LC_MESSAGES problem ?


On Mon, Nov 20, 2000 at 01:23:03PM -0800, Ulrich Drepper wrote:
> wkpark <wkpark@chem.skku.ac.kr> writes:
> 
> > Yes. I know about this.  but, the automatic translation is not
> > working with setlocale(LC_MESSAGES,"") only. (remember the subject
> > of this thread :-)
> 
> You were talking about Unicode environments which means you use a
> Unicode (aka UTF-8) locale.
>

It so hard to conversation :-(

with utf8 locale(like ko_KR.utf8), does automatic translation working correct
with setlocale(LC_MESSAGES,"") only program ??

in my situation, with UTF8 locale, I can't get correct translation message also.

with below ugly program (like gcc)
-------------------------------
#include <stdio.h>
#include <errno.h>
#include <locale.h>

int main()
{
        errno=2;
//        setlocale(LC_CTYPE, "");
        setlocale(LC_MESSAGES, "");
        perror("aaa");
        return 1;
}

------------------------------
$ LC_MESSAGES=ko_KR.utf8 ./a.out
aaa: ?? ???? ????? ??
(not working)

$ OUTPUT_CHARSET=UTF8 LC_CTYPE=ko_KR.utf8 ./a.out
aaa: xxxxxxx xxxxxx xxxxxxx
(working)

$ ls /usr/lib/locale/ko_KR.utf8 -al
합계 584
drwxr-xr-x    3 root     root         4096 10월 18 07:11 .
drwxr-xr-x  138 root     root         4096 11월 20 19:35 ..
-rw-r--r--    1 root     root          117 10월  6 06:13 LC_ADDRESS
-rw-r--r--    1 root     root       454648 10월  6 06:13 LC_COLLATE
-rw-r--r--    1 root     root        84804 10월  6 06:13 LC_CTYPE
-rw-r--r--    1 root     root          157 10월  6 06:13 LC_IDENTIFICATION
-rw-r--r--    1 root     root           13 10월  6 06:13 LC_MEASUREMENT
drwxr-xr-x    2 root     root         4096 11월 21 06:39 LC_MESSAGES
-rw-r--r--    1 root     root          284 10월  6 06:13 LC_MONETARY
-rw-r--r--    1 root     root           52 10월  6 06:13 LC_NAME
-rw-r--r--    1 root     root           44 10월  6 06:13 LC_NUMERIC
-rw-r--r--    1 root     root           24 10월  6 06:13 LC_PAPER
-rw-r--r--    1 root     root           39 10월  6 06:13 LC_TELEPHONE
-rw-r--r--    1 root     root         2121 10월  6 06:13 LC_TIME

$ LANG=ko_KR.utf8 date
xxx xxx xx 11xx 21 07:07:33 KST 2000
(working)

$ rpm -q glibc
glibc-2.1.94-3

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]