On 06/16/2011 07:23 PM, Mark Knecht wrote:
On Thu, Jun 16, 2011 at 9:00 AM, Paul Hartman
<paul.hartman+gen...@gmail.com>  wrote:
On Thu, Jun 16, 2011 at 10:45 AM, Mark Knecht<markkne...@gmail.com>  wrote:
Is there a simple explanation concerning the difference between the
two locales I have seen on Gentoo machines?

1) /etc/locale, as specified in the installation documents

2) /etc/env.d/02locale as has been discussed on the list recently

I'm not near a Gentoo machine right now, but off the top of my head IIRC:

/etc/locale.gen contains a list of locales to be compiled when glibc
is emerged. These will be available to be used.

/etc/env.d/02locale specifies which of those locales you actually want
to use for the system-wide default (the LC variables)

Thanks for the response Paul.

Does that mean that the /etc/locale.gen is used only by glibc and not
really by the system? If so, what is glibc doing with these beyond
letting me system run programs?

It allows you to have locales to use in /etc/env.d/02locale ;-) If you want to set LANG=en_US.UTF-8 in 02locale, you of course need the files for that specific locale/encoding. To get them, you need to write "en_US.UTF-8 UTF-8" in locale.gen. Not sure why you're not getting the comments in your locale.gen, but here there are, at the top of the file:

# /etc/locale.gen: list all of the locales you want to have on your system
#
# The format of each line:
# <locale> <charmap>
#
# Where <locale> is a locale located in /usr/share/i18n/locales/ and
# where <charmap> is a charmap located in /usr/share/i18n/charmaps/.
#
# All blank lines and lines starting with # are ignored.
#
# For the default list of supported combinations, see the file:
# /usr/share/i18n/SUPPORTED
#
# Whenever glibc is emerged, the locales listed here will be automatically
# rebuilt for you. After updating this file, you can simply run `locale-gen`
# yourself instead of re-emerging glibc.


Reply via email to