Author: matthew Date: 2005-04-17 05:32:36 -0600 (Sun, 17 Apr 2005) New Revision: 4985
Modified: branches/6.1/BOOK/chapter01/changelog.xml branches/6.1/BOOK/chapter07/profile.xml Log: * Use canonical charmaps in /etc/profile and don't set LC_ALL (merge r4984 from trunk) Modified: branches/6.1/BOOK/chapter01/changelog.xml =================================================================== --- branches/6.1/BOOK/chapter01/changelog.xml 2005-04-17 11:27:20 UTC (rev 4984) +++ branches/6.1/BOOK/chapter01/changelog.xml 2005-04-17 11:32:36 UTC (rev 4985) @@ -82,6 +82,9 @@ </itemizedlist> </listitem> +<listitem><para>April 17, 2005 [matt]: Use canonical charmaps in /etc/profile +and don't set LC_ALL (Ken Moffat and Alexander Patrakov)</para></listitem> + <listitem><para>April 16, 2005 [matt]: Reword handling of hotpluggable devices now that we install the hotplug package (Andrew Benton)</para></listitem> Modified: branches/6.1/BOOK/chapter07/profile.xml =================================================================== --- branches/6.1/BOOK/chapter07/profile.xml 2005-04-17 11:27:20 UTC (rev 4984) +++ branches/6.1/BOOK/chapter07/profile.xml 2005-04-17 11:32:36 UTC (rev 4985) @@ -60,14 +60,10 @@ <para>Replace <replaceable>[ll]</replaceable> below with the two-letter code for the desired language (e.g., <quote>en</quote>) and <replaceable>[CC]</replaceable> with the two-letter code for the -appropriate country (e.g., <quote>GB</quote>). It may also be -necessary to specify (and this is actually the preferred form) the -character encoding (e.g. <quote>iso8859-1</quote>) after a dot (so -that the result is <quote>en_GB.iso8859-1</quote>). Issue the -following command for more information:</para> +appropriate country (e.g., <quote>GB</quote>). +<replaceable>[charmap]</replaceable> should be replaced with the +canonical charmap for your chosen locale.</para> -<screen><userinput>man 3 setlocale</userinput></screen> - <para>The list of all locales supported by Glibc can be obtained by running the following command:</para> @@ -75,14 +71,31 @@ <beginpage/> +<para>Locales can have a number of synonyms, e.g. <quote>ISO-8859-1</quote> is +also referred to as <quote>iso8859-1</quote> and <quote>iso88591</quote>. +Some applications cannot handle the various synonyms correctly, so it is safest +to choose the canonical name for a particular locale. To determine the +canonical name, run the following command, where +<replaceable>[locale name]</replaceable> is the output given by +<command>locale -a</command> for your preferred locale +(<quote>en_GB.iso88591</quote> in our example).</para> + +<screen><userinput>LC_ALL=<replaceable>[locale name]</replaceable> locale charmap</userinput></screen> + +<para>For the <quote>en_GB.iso88591</quote> locale, the above command +will print:</para> + +<screen>ISO-8859-1</screen> + +<para>This results in in a final locale setting of <quote>en_GB.ISO-8859-1</quote>.</para> + <para>Once the proper locale settings have been determined, create the <filename>/etc/profile</filename> file:</para> <screen><userinput>cat > /etc/profile << "EOF" <literal># Begin /etc/profile -export LC_ALL=<replaceable>[ll]</replaceable>_<replaceable>[CC]</replaceable> -export LANG=<replaceable>[ll]</replaceable>_<replaceable>[CC]</replaceable> +export LANG=<replaceable>[ll]</replaceable>_<replaceable>[CC]</replaceable>.<replaceable>[charmap]</replaceable> export INPUTRC=/etc/inputrc # End /etc/profile</literal> -- http://linuxfromscratch.org/mailman/listinfo/lfs-book FAQ: http://www.linuxfromscratch.org/lfs/faq.html Unsubscribe: See the above information page
