Para empezar, se ha de editar el archivo /etc/make.conf y añadir el flag "unicode" a los USE si no lo tenías habilitado. Para recompilar todos los programas para que soporten Unicode puedes usar:
emerge -uDv --newuse world
Seguidamente configuramos los 'locale', los generamos, activamos unicode en el rc.conf y la fuente de consola. Podéis comprobar los archivos en este código:
/etc/locale.gen:
# /etc/locale.gen: list all of the locales you want to have on your system
#
# The format of each line:
#
#
# Whereis a locale located in /usr/share/i18n/locales/ and
# whereis 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.
en_US ISO-8859-1
en_US.UTF-8 UTF-8
es_ES.UTF-8 UTF-8
/etc/env.d/02locale:
LC_ALL="es_ES.UTF-8"
LC_COLLATE="es_ES.UTF-8"
LC_CTYPE="es_ES.UTF-8"
LC_MESSAGES="es_ES.UTF-8"
LC_MONETARY="es_ES.UTF-8"
LC_NUMERIC="es_ES.UTF-8"
LC_PAPER="es_ES.UTF-8"
LANG="es_ES.UTF-8"
Generamos los locale definidos:
naguissa@Turion64 ~ $ sudo locale-gen
* Generating 3 locales (this might take a while) with 1 jobs
* (1/3) Generating en_US.ISO-8859-1 ... [ ok ]
* (2/3) Generating en_US.UTF-8 ... [ ok ]
* (3/3) Generating es_ES.UTF-8 ... [ ok ]
* Generation complete
/etc/rc.conf:
Ponemos a "yes" la variable de UNICODE:
UNICODE="yes"
/etc/conf.d/consolefont:
# /etc/conf.d/consolefont
# CONSOLEFONT specifies the default font that you'd like Linux to use on the
# console. You can find a good selection of fonts in /usr/share/consolefonts;
# you shouldn't specify the trailing ".psf.gz", just the font name below.
# To use the default console font, comment out the CONSOLEFONT setting below.
# This setting is used by the /etc/init.d/consolefont script (NOTE: if you do
# not want to use it, run "rc-update del consolefont" as root).
#CONSOLEFONT="default8x16"
CONSOLEFONT="lat9w-16"
# CONSOLETRANSLATION is the charset map file to use. Leave commented to use
# the default one. Have a look in /usr/share/consoletrans for a selection of
# map files you can use.
#CONSOLETRANSLATION="8859-1_to_uni"
Y con ésto hemos terminado la traducción al español con soporte unicode.
Os dejo unas capturas:
Consola funcionando en unicode (fotos, se ven fatal):
Gnome funcionando en unicode:
Aun así, hay programas mal codificados que nos saldrán mal:
(pese a que muchas páginas estan correctas)
Editado por Daniel el 21/05/2008 a las 04:40:10h.