|
PKGBUILD- # Contributor: Tan Xiang <txcary@gmail.com>
- # Contributor: Lee.MaRS <leemars@gmail.com>
- pkgname=wqy-bitmapfont
- pkgver=0.8.0
- pkgrel=2
- pkgdesc="Wenquanyi bitmap font"
- url="http://wenq.org/"
- depends=("fontconfig" "rpmextract")
- install=xfonts.install
- source=(http://dl.sourceforge.net/wqy/wqy-bitmapfont-0.8.0-6.noarch.rpm)
- md5sums=('4a8f88b41cbb15ae26d859904984590f')
- build() {
- _dirname="/usr/share/fonts/wenquanyi/wqy-bitmapfont"
- mkdir -p $startdir/src/$pkgname
- cd $startdir/src/$pkgname
- rpmextract.sh $startdir/src/wqy-bitmapfont-0.8.0-6.noarch.rpm || return 0
- cd $startdir/src/$pkgname/$_dirname
- mkdir -p $startdir/pkg/$_dirname
- cp *.pcf $startdir/pkg/$_dirname
- cp fonts.alias $startdir/pkg/$_dirname
- mkdir -p $startdir/pkg/etc/fonts/conf.d
- mkdir -p $startdir/pkg/etc/fonts/conf.avail
- cp 85-wqy-bitmapsong.conf $startdir/pkg/etc/fonts/conf.avail
- cd $startdir/pkg/etc/fonts/conf.d
- ln -s ../conf.avail/85-wqy-bitmapsong.conf
- }
复制代码
xfonts.install- post_install() {
- echo -n "Updating font cache... "
- cd /usr/share/fonts/wenquanyi/wqy-bitmapfont/
- rm fonts.dir fonts.scale fc-cache.*
- mkfontdir .
- cp fonts.dir fonts.scale
- fc-cache -f /usr/share/fonts/wenquanyi/wqy-bitmapfont/
- echo "done."
- }
- post_upgrade() {
- post_install $1
- }
- post_remove() {
- post_install $1
- }
- op=$1
- shift
- $op $*
复制代码 |
|