IceWalkers.com - Linux Software downloads and news
Name : Password :
Linux SoftwareLinux RPMLinux HowtosLink UsAboutAdvertise

The Linux Danish/International HOWTO

Search Howtos :Match :
Next Previous Contents

5. Locale support in libc 5.4.x and higher

The locale support has been updated in libc 5.4.x. You can avoid many of the individual program setups described in section International character sets in specific applications if the programs on your system is prepared for locale support. The Debian distribution comes with this support if you install the wg15-locale package. Systems with GNU libc 2 (libc 6.x) support locales by default (see remarks about Red Hat Linux release 5.0 later in this section.)

If you use a system without locale support, you can add such support using the following method:

  1. Make sure you have the latest libc 5.4.x library. You can get this from Yggdrasil Computing.
  2. Make sure you have the localedef program installed. It should come with the library.
  3. Get the locale sources. You can get them from DKUUG. You need to get both locale and charmap sources.
  4. Put the locale sources in /usr/share/i18n/locales/ and the charmap sources in /usr/share/i18n/charmaps/.
  5. Execute the localedef program to build the locale data files:
    localedef -ci da_DK -f ISO_8859-1:1987 da_DK
    
    (Note for non-Danish readers: You can build locale data files for other locales in the same way. All locale and charmap sources are at the DKUUG site.)

To enable support for the Danish locale on a system with locale support you just have to set one of the following environment variables:

LANG=da_DK
or
LC_ALL=da_DK

Try da_DK.ISO_8859-1 if da_DK does not work.

Both environment variables set all the individual locale catgories. You can also set a single locale category by using the name of the category as an environment variable. The locale catogories are:

Locale category         Application
---------------         -----------
LC_COLLATE              Collation of strings (sort order.)
LC_CTYPE                Classification and conversion of characters.
LC_MESSAGES             Translations of yes and no.
LC_MONETARY             Format of monetary values.
LC_NUMERIC              Format of non-monetary numeric values. 
LC_TIME                 Date and time formats.
LC_ALL                  Sets all of the above (overrides all of them.)
LANG                    Sets all the categories, but can be overridden
                        by the individual locale categories.

In Red Hat Linux 5.2 you can set the environment variables LANG and/or LC_ALL in the file /etc/sysconfig/i18n by adding lines such as this:

LC_ALL=da_DK

A few programs such as bash and GNU emacs still need specific setup as described in section International character sets in specific applications, but most should work without further attention. Programs such as nvi which did not work with 8 bit characters before should work now.

Locale support should be more common as distributions based on the new GNU libc 2 become available. Beware that although Red Hat Linux release 5.0 comes with GNU libc 2, the locale support is not working. You have to build the locale data files by executing localedef yourself. You can build the Danish locale data files with the following command:

localedef -c -i da_DK -f ISO-8859-1 da_DK

As of glibc-2.0.7-4.i386.rpm the locale data files are included with the libraries and this is no longer necessary.


Next Previous Contents
Search Howtos :Match :
ImageMagick 6.6.0-5
ImageMagick image processing studio
Evolution 2.29.92.1
GNOME mailer, calendar, contact manager and communications tool
PgAdmin III 1.10.2
Powerfull administration and development tools for PostgreSQL
NASM 2.08.01
NASM is an 80x86 assembler designed for portability
Glade 3.7.0
User interface builder for GTK+ and Gnome
Monkey HTTP Daemon 0.10.0-rc2
Monkey is a small and fast web server for linux
Efax-gtk 3.2.0
GUI front end for the efax fax program
Brasero 2.29.92
Application to burn CD/DVD
GtkHTML 3.29.92.1
HTML rendering/editing library
LimeWire 5.5.5
Gnutella Client
Free IT Magazines, White Papers, eBooks, and more !
Oracle Magazine

Contains technology strategy articles, sample code, tips, Oracle and partner news, how to articles for developers and DBAs, and more.

Vulnerability Management for Dummies

Get all the Facts and See How to Implement a Successful Vulnerability Management Program.

Website Magazine

Has tapped premier talent in the Internet industry for our content and each and every issue will contain practical advice and insights for website owners.

Linux Software Map
Find Linux RPM
Best Rated Linux Software
Most Rated Linux Software
Linux Distributions
Linux Howtos
Quick Survey

Please take our survey and help us improve our website to serve you better.

Thank you.
Linux Software
Linux / IT Resources
Site Resources
Google
Privacy Policy
Contact Us
Submit Software
Advertising info