void-packages/srcpkgs/dina-font/template
2019-02-18 09:29:50 -03:00

45 lines
1.1 KiB
Bash

# Template file for 'dina-font'
pkgname=dina-font
version=2.93
revision=1
archs=noarch
create_wrksrc=yes
font_dirs="/usr/share/fonts/X11/misc"
hostmakedepends="bdftopcf font-util unzip"
depends="font-util"
short_desc="Monospace bitmap font, primarily aimed at programmers"
maintainer="Lee Wang <lee.wang.gretzky@gmail.com>"
license="Custom"
homepage="http://www.donationcoder.com/Software/Jibz/Dina/index.html"
distfiles="http://ftp.osuosl.org/pub/gentoo/distfiles/dina-${version}.zip"
checksum=47792817b7716577727a488952b9892b16966a45dc3ba52e026d59b9d9e20695
_ex_pt() {
_pt=${1%.bdf}
_pt=${_pt#*-}
echo $_pt
}
do_install() {
cd BDF
sed -i 's/microsoft-cp1252/ISO8859-1/' *.bdf
for i in Dina_i400-*.bdf; do
bdftopcf -t -o DinaItalic$(_ex_pt $i).pcf $i
done
for i in Dina_i700-*.bdf; do
bdftopcf -t -o DinaBoldItalic$(_ex_pt $i).pcf $i
done
for i in Dina_r400-*.bdf; do
bdftopcf -t -o DinaMedium$(_ex_pt $i).pcf $i
done
for i in Dina_r700-*.bdf; do
bdftopcf -t -o DinaBold$(_ex_pt $i).pcf $i
done
for i in *.pcf; do
gzip "$i"
done
vmkdir usr/share/fonts/X11/misc
install -m644 *.pcf.gz ${DESTDIR}/usr/share/fonts/X11/misc
vlicense ../LICENSE
}