Gentoo Wiki


Support is available in the Gentoo Forums under Desktop Environments. Make sure to include all the appropriate versions of things - like kde-3.3.4.

The objective of this HOWTO is to make your Gentoo box display the Japanese written language. Users may want to have a look at Using UTF-8 with Gentoo or the local wiki page on the same subject. Once you have set up your Japanese fonts, you may wish to have a look at Input Methods for how to input these.


Japanese Fonts

You need to install fonts for your applications to display when they encounter Japanese characters. A good sign that you have not installed the proper fonts is that the following characters appear as boxes with numbers inside: 日本語フォント.

Some relevant packets:

It never hurts to get them all.

There are other cjk and unicode fonts available in the portage tree, to be found with

emerge -s fonts

or if you have esearch installed, you can do a quicker search with

esearch fonts

Fonts outside portage

Japanese Unicode Fonts includes a nice list of fonts outside portage.

corefonts-cjk. Bug 123729 has an ebuild (corefonts-cjk) for installing cjk fonts associated with Internet Explorer.

Arial Unicode MS is another great font, which you may or may not have access to. There have been reports of errors in emulators while using this font, but this same procedure can be followed for any Microsoft-provided truetype fonts you may find:

emerge cabextract

Find a copy of aruniupd.exe - online availability changes. As of write:

cabextract aruniupd.exe

For system-wide installation use

cp *.ttf /usr/share/fonts/

for local installation (no root access)

cp *.ttf ~/.fonts/


fc-cache -fv

Programs will probably have to be restarted to access new fonts.

Arial Unicode MS should now be available on your system. Web browsers like Firefox should probably have this mentioned in their settings. Specifically, in Mozilla Firefox, look at

See Preferences >> General >> Fonts & colors >> Fonts for: Japanese

Java 1.4.x

This has been tested on blackdown-jdk- :

cd $JAVA_HOME/jre/lib/
cat | sed "s/-watanabe-mincho/-misc-Kochi Mincho-medium/g" | sed "s/-wadalab-gothic-medium/-misc-Kochi Gothic-medium/g" >
echo 'appendedfontpath=/usr/share/fonts/kochi-substitute' >>
/usr/sbin/env-update && source /etc/profile

Java 1.5

With Sun Java 1.5, things are much easier, as it supports 'fallback fonts'. You have to create a subfolder called 'fallback' in the JRE fonts directory. Copy a Japanese font into it or create a symlink and you're done. In this example we'll use cyberbit.ttf, but any other TTF font will work as well, as long as it contains the characters you want to use in your Java 1.5 applications.

mkdir /opt/sun-jdk-*/jre/lib/fonts/fallback
cd /opt/sun-jdk-*/jre/lib/fonts/fallback
ln -s /usr/share/fonts/TTF/cyberbit.ttf cyberbit.ttf


CJK fonts sometimes cause xorg-x11 compiled with the flag hardened to fail when starting up. Reference

Gjiten and Kiten (the latter a part of kdeedu) are Japanese dictionary programs, using EDICT. Gjiten is more comprehensive, but requires you to manually install dictionaries. Nihongo Benkyo is another possibility, Bug 112894 for ebuilds

See also

Support is available in the Gentoo Forums under Desktop Environments. Make sure to include all the appropriate versions of things - like kde-3.3.4.

Retrieved from ""

Last modified: Sat, 06 Sep 2008 15:09:00 +0000 Hits: 19,837