Question about ELDK and i18n...

Wolfgang Denk wd at
Thu Sep 1 19:18:01 EST 2005

Dear David,

in message <200509011009.24114.david.jander at> you wrote:
> I am using ELDK-3.1, and I am not getting i18n to work. I have looked at 
> recent changelog of ELDK and newer (CVS) versions don't seem to fix any bug 
> in that direction.

There is no fix yet, but the problem is known :-(

> The installation seems ok, the locale-files are all there as it seems.


> I have tried this as a test:
> # LANG=es_ES strace tar
> in the output, I can see these relevant lines:
> open("/usr/lib/locale/locale-archive", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No 
> such file or directory)
> - This does not matter.

It does. For the setlocale() call to succeed, an additional file is
needed, apart from the locale files themselves. It is a
locale-archive file in the /usr/lib/locale directory on the target.
This file is still missing in the ELDK glibc RPM.

> open("/usr/share/locale/locale.alias", O_RDONLY) = 3
> - OK, good. locale.alias is read
> open("/usr/lib/locale/es_ES/LC_IDENTIFICATION", O_RDONLY) = 3
> - Also looks fine, read the locales identification.
> open("/usr/lib/locale/es/LC_IDENTIFICATION", O_RDONLY) = -1 ENOENT (No such 
> file or directory)
> - Here I am puzzled. Why? Maybe this is not important.
> Then there are no more calls to open or stat with files in "/usr/lib/locale" 
> nor "/usr/share/locale" as argument, and I can't figure out why. What am I 
> doing wrong? Is this version of glibc in ELDK broken?

There  is  a  problem  with  locale  support.  The  contents  of  the
'locale-archive'  file  is endian-dependent. This means that we can't
use the existing tools on the x86 (= little endian) ELDK  build  host
to generate it for a big-endian target.

As a workaround, the locale files can be generated  natively  on  the
target, using for example the following command:

# localedef -i de_DE -f ISO-8859-1 de_DE

Hope this helps.

Best regards,

Wolfgang Denk

Software Engineering:  Embedded and Realtime Systems,  Embedded Linux
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at
There is, however, a strange, musty smell in the air that reminds  me
of something...hmm...yes...I've got it...there's a VMS nearby, or I'm
a Blit.          - Larry Wall in Configure from the perl distribution

More information about the Linuxppc-embedded mailing list