In order to keep time properly,
# ln -sf /usr/share/zoneinfo/Europe/Berlin /etc/localtime # date Sun Feb 16 08:26:44 CET 2003
In most Gentoo Linux installations, your hardware clock is set to
UTC (or GMT, Greenwich Mean Time) and then your timezone is
taken into account to determine the actual, local time. If,
for some reason, you need your hardware clock not to be in UTC,
you will need to edit
(recommended:) CLOCK="UTC"(or:) CLOCK="local"
A Locale is a set of information that most programs use for determining
country and language specific settings. The locales and their data
are part of the system library and can be found
at
Locale settings are stored in environment variables. These are typically
set in the
Variable name | Explanation |
---|---|
Most typically users only set the LANG variable and perhaps LC_CTYPE variable on user level by adding definitions to shells startup files defining the environment variable manually from command line:
export LANG="de_DE@euro"
For message based localization to work in programs that support it, you will
probably need to have programs compiled with the
If you use a locale that isn't available by default, you should use
# localedef -c -i en_US -f ISO-8859-15 en_US.ISO-8859-15
After having generated the locale, you can export the LANG variable as you see fit.
# export LANG="en_US.ISO-8859-15"
You will probably only use one or maybe two locales on your system. Up until now
after compiling
echo "sys-libs/glibc userlocales" >> /etc/portage/package.use
Now specify the locales you want to be able to use:
en_US/ISO-8859-1 en_US.UTF-8/UTF-8 de_DE/ISO-8859-1 de_DE@euro/ISO-8859-15
The next step is to re-compile
The keyboard layout used by the console is set in
KEYMAP="de" KEYMAP="de-latin1" KEYMAP="de-latin1-nodeadkeys"
The keyboard layout to be used by the X server is specified
in
Section "InputDevice" Identifier "Keyboard1" ... Option "XkbLayout" "de" # Option "XkbVariant" "nodeadkeys" ...
For KDE you have to install the kde-i18n package with the appropriate LINGUAS variable set:
# nano -w /etc/make.conf(Add in the LINGUAS variable. For instance, for the German language:) LINGUAS="de"(Now install kde-i18n) # emerge kde-i18n
In order to get your console to display the Euro symbol, you
will need to set
CONSOLEFONT="lat9w-16"
Getting the Euro symbol to work properly in X is a little
bit tougher. The first thing you should do is change the
fixed -misc-fixed-medium-r-semicondensed--13-120-75-75-c-60-iso8859-15 variable -*-helvetica-bold-r-normal-*-*-120-*-*-*-*-iso8859-15
Some applications use their own font, and you will have to
tell them separately to use a font with the Euro symbol. You
can do this at a user-specific level in
(in your home directory) # echo 'XTerm*font: fixed' >> .Xresources # xrdb -merge .Xresources
To use the Euro symbol in (X)Emacs, add the following to
Emacs.default.attributeFont: -*-courier-medium-r-*-*-*-120-*-*-*-*-iso8859-15
For XEmacs (not plain Emacs), you have to do a little
more. In
(define-key global-map '(EuroSign) '[€])
Please note that this package now uses the LINGUAS variable to
provide localization. The old LANGUAGE=ENUS|PORT system does
# nano -w /etc/make.conf(Add in the LINGUAS variable. For instance, for the German language:) LINGUAS="de"(Now install openoffice) # emerge openoffice