openSUSE-12.2にRictyフォントを導入する際の注意
Abstract
openSUSE-12.2環境に置いて`./ricty-generator.sh auto`はシステムに導入されたInconsolata/M+ 1M regular/M+ 1M boldの各フォントファイルを見つけてくれない。
% ./ricty-generator.sh auto ... Error: ... not found
手作業で各フォントを指定する必要がある。更に言うとopenSUSE-12.2のInconsolata/M+ 1M regular/M+ 1M boldの各フォントのファイル名はricty-generator.shの想定とは異なるので注意を要する。
Method
1. Inconsolata 導入
% zypper in inconsolata
...
※ inconsolata または google-inconsolata-fonts → software.opensuse.org: パッケージにより /usr/share/fonts/truetypeに導入されるファイル名が異なる場合もあるので注意。
2. M+ 導入
% zypper in mplus-fonts
3. ricty-generator.sh
% git clone git@github.com:yascentur/Ricty.git ... % cd Ricty % ln -s /usr/share/fonts/truetype/inconsolata.otf Inconsolata.otf % ln -s /usr/share/fonts/truetype/mplus-1m-regular.ttf migu-1m-regular.ttf % ln -s /usr/share/fonts/truetype/mplus-1m-bold.ttf migu-1m-bold.ttf % ./rictry-generator auto
inconsolata.otfではなくInconsolata.otfにしておく辺りに特に注意。
4. checkinstallでrpm化し導入
install用にMakefileを書く。
% gvim Makefile ...
all: install: install -m 644 *.ttf /usr/share/fonts/truetype
checkinstallでrpmにする。
% sudo su % checkinstall ...
rpmを導入する。
% rpm -i /usr/src/packages/RPMS/x86_64/Ricty-20121208-1.x86_64.rpm
Alternative
上記 3. では`ln -s`により作業ディレクトリーに合成元のフォントファイルのリンクをricty-generator.shにautoオプションで都合の良い様に作成したが、autoオプションに寄らずコマンドラインで設定しても構わない。
% ./ricty-generator /usr/(略)/inconsolata.otf /usr/(略)/mplus-1m-regular.ttf (略)-bold.ttf