Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 148236 - Improper use of LC_ALL in "Using UTF-8 with Gentoo"
Summary: Improper use of LC_ALL in "Using UTF-8 with Gentoo"
Status: RESOLVED FIXED
Alias: None
Product: [OLD] Docs on www.gentoo.org
Classification: Unclassified
Component: Other documents (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: nm (RETIRED)
URL: http://www.gentoo.org/doc/en/utf-8.xml
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-09-19 12:12 UTC by Akos Ladanyi
Modified: 2006-10-06 11:36 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Akos Ladanyi 2006-09-19 12:12:54 UTC
In the "Using UTF-8 with Gentoo" guide it is suggested to set the LC_ALL variable in /etc/env.d/02locale. This is not right, LANG shoud be used instead. See this mailinglist thread for exlanations: 
http://mail.nl.linux.org/linux-utf8/2003-03/msg00014.html

As a sidenote, this causes bugs like this: Bug 134834.
Comment 1 SpanKY gentoo-dev 2006-09-19 15:44:15 UTC
reason being that LC_ALL overrides everything and does not allow for customization of different locale aspects

if you set just LANG, that gives a system default which can be tweaked based upon other LC_* vars and in the case of debugging, can be quickly overridden by setting LC_ALL
Comment 2 nm (RETIRED) gentoo-dev 2006-09-28 04:55:00 UTC
(In reply to comment #0)
> In the "Using UTF-8 with Gentoo" guide it is suggested to set the LC_ALL
> variable in /etc/env.d/02locale. This is not right, LANG shoud be used instead.
> See this mailinglist thread for exlanations: 
> http://mail.nl.linux.org/linux-utf8/2003-03/msg00014.html
> 
> As a sidenote, this causes bugs like this: Bug 134834.
> 

LC_ALL can, however, be used on most systems without causing problems. I've had no issues with LC_ALL. The guide should instead make note that LC_ALL is optional, and may have different effects depending on what other (screwy) things users may be doing with their systems.
Comment 3 SpanKY gentoo-dev 2006-09-28 05:08:45 UTC
it's not a matter of LC_ALL not working, it's a matter of using LC_ALL to control your settings is the wrong methodology

LC_ALL is the master override ... users should be specifying a default via LANG
Comment 4 nm (RETIRED) gentoo-dev 2006-10-06 10:49:07 UTC
(In reply to comment #3)
> it's not a matter of LC_ALL not working, it's a matter of using LC_ALL to
> control your settings is the wrong methodology
> 
> LC_ALL is the master override ... users should be specifying a default via LANG
> 

Here's a link mentioned in the original CVS commit that changed LANG to LC_ALL:

http://www.gnu.org/software/libc/manual/html_node/Locale-Categories.html#Locale-Categories

Original commit diff:
http://sources.gentoo.org/viewcvs.py/gentoo/xml/htdocs/doc/en/utf-8.xml?r1=1.15&r2=1.16

That being said, I'll take a look at changing the doc to mentioning LC_ALL is still available as an option.

Comment 5 SpanKY gentoo-dev 2006-10-06 11:23:07 UTC
that diff didnt change LANG to LC_ALL, it stopped mentioning both LANG and LC_ALL together as setting LANG in addition to LC_ALL is indeed pointless as LC_ALL overrides LANG
Comment 6 nm (RETIRED) gentoo-dev 2006-10-06 11:36:58 UTC
Changed LC_ALL to recommending LANG as the default, though I added a note on setting LC_ALL if desired.

Fixed in CVS, thanks for reporting and for all the comments on the bug.