Gentoo Archives: gentoo-user

From: Mick <michaelkintzios@×××××.com>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] Questions regarding the usage of multiple locales
Date: Sat, 26 Jun 2010 11:30:05
Message-Id: 201006261229.26879.michaelkintzios@gmail.com
In Reply to: Re: [gentoo-user] Questions regarding the usage of multiple locales by Alex Schuster
1 On Saturday 26 June 2010 12:10:02 Alex Schuster wrote:
2 > Mick writes:
3
4 > > Oops! This is more complicated that I thought ...
5 > >
6 > > If, always as a plain user, I use aterm then /etc/env.d/02locale is
7 > > read and LANG is en_GB.UTF-8. However, if I use xterm it is still
8 > > LANG=en_US.UTF-8
9 >
10 > Your aterm is configured as a login shell, and as such reads /etc/profile,
11 > which reads /etc/profile.env (and ~/.[bash]profile). xterm is not a login
12 > shell, and reads /etc/bash/bashrc (and ~/.bashrc). You can call xterm with
13 > the -ls option to make it alogin shell. For konsole, I have set it to
14 > execute bash -l to make it a login shell.
15 >
16 > Another workaround might be to read /etc/profile.env in your .bashrc, or
17 > in /etc/bash/bashrc.
18
19 Hmm... I've added all this in my /etc/env.d/02locale:
20
21 LANG="en_GB.UTF-8"
22 LC_CTYPE="en_GB.UTF-8"
23 LC_NUMERIC="en_GB.UTF-8"
24 LC_TIME="en_GB.UTF-8"
25 LC_COLLATE="C"
26 LC_MONETARY="en_GB.UTF-8"
27 LC_MESSAGES="en_GB.UTF-8"
28 LC_PAPER="en_GB.UTF-8"
29 LC_NAME="en_GB.UTF-8"
30 LC_ADDRESS="en_GB.UTF-8"
31 LC_TELEPHONE="en_GB.UTF-8"
32 LC_MEASUREMENT="en_GB.UTF-8"
33 LC_IDENTIFICATION="en_GB.UTF-8"
34
35 and in my ~/.bashrc
36
37 export LANG="en_GB.UTF-8"
38 export LC_CTYPE="en_GB.UTF-8"
39 export LC_NUMERIC="en_GB.UTF-8"
40 export LC_TIME="en_GB.UTF-8"
41 export LC_COLLATE="C"
42 export LC_MONETARY="en_GB.UTF-8"
43 export LC_MESSAGES="en_GB.UTF-8"
44 export LC_PAPER="en_GB.UTF-8"
45 export LC_NAME="en_GB.UTF-8"
46 export LC_ADDRESS="en_GB.UTF-8"
47 export LC_TELEPHONE="en_GB.UTF-8"
48 export LC_MEASUREMENT="en_GB.UTF-8"
49 export LC_IDENTIFICATION="en_GB.UTF-8"
50
51 but this is what aterm is showing:
52
53 $ locale
54 LANG=en_GB.UTF-8
55 LC_CTYPE="en_US.UTF-8"
56 LC_NUMERIC="en_US.UTF-8"
57 LC_TIME="en_US.UTF-8"
58 LC_COLLATE="en_US.UTF-8"
59 LC_MONETARY="en_US.UTF-8"
60 LC_MESSAGES="en_US.UTF-8"
61 LC_PAPER="en_US.UTF-8"
62 LC_NAME="en_US.UTF-8"
63 LC_ADDRESS="en_US.UTF-8"
64 LC_TELEPHONE="en_US.UTF-8"
65 LC_MEASUREMENT="en_US.UTF-8"
66 LC_IDENTIFICATION="en_US.UTF-8"
67 LC_ALL=en_US.UTF-8
68
69 There's no mention of LANG or LC_*US* in /etc/profile.env, /etc/bash/bashrc,
70 or anywhere else that I can see. So, where is it being read from?
71
72 PS. Not sure why LANG=en_GB.UTF-8 does not have " " marks like the LC_
73 parameters?
74 --
75 Regards,
76 Mick

Attachments

File name MIME type
signature.asc application/pgp-signature

Replies

Subject Author
Re: [gentoo-user] Questions regarding the usage of multiple locales Alex Schuster <wonko@×××××××××.org>
Re: [gentoo-user] Questions regarding the usage of multiple locales Joerg.Schilling@fokus.fraunhofer.de (Joerg Schilling)