[Nix-dev] Re: perl: warning: Setting locale failed.
Ludovic Courtès
ludo at gnu.org
Sun May 31 17:31:06 CEST 2009
Lluís Batlle <viriketo at gmail.com> writes:
> stracing shows that the 'locale' commandline isn't caring on
> LOCALE_ARCHIVE.
Hmm, it apparently *does* honor that variable, and it does open the
77 MiB locale archive, too:
--8<---------------cut here---------------start------------->8---
$ locale --version
locale (GNU libc) 2.9
Copyright (C) 2008 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
Written by Ulrich Drepper.
$ strace -f -o ,,s locale -a
C
POSIX
$ grep locale-archive ,,s
6108 open("/var/run/current-system/sw/lib/locale/locale-archive", O_RDONLY|O_LARGEFILE) = 3
6108 open("/nix/store/v52qk62nsj4fx9m79755caijcgpndclc-glibc-2.9/lib/locale/locale-archive", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
$ LOCALE_ARCHIVE=/foo/bar strace -f -o ,,s locale -a
locale: Cannot set LC_CTYPE to default locale: No such file or directory
locale: Cannot set LC_MESSAGES to default locale: No such file or directory
locale: Cannot set LC_COLLATE to default locale: No such file or directory
C
POSIX
$ grep /foo/bar ,,s
6129 open("/foo/bar", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
--8<---------------cut here---------------end--------------->8---
Ludo'.
More information about the nix-dev
mailing list