freebsd-ports/x11-fonts/cyberbit-ttfonts/pkg-install
Maho Nakata 0bec1d1481 Add cyberbit-ttfonts.
Bitstream Cyberbit is a TrueType font. It is an international font, containing
characters from many languages. Each character is encoded with its Unicode
value, according to Unicode 2.0 standards.

Cyberbit was developed by Bitstream to provide Unicode Consortium members with
a test font. It is therefore distributed freely to customers that need advanced
multilingual fonts for testing and other non-commercial uses. Customers that
wish to use Cyberbit for other purposes must license the font from Bitstream.
2005-02-10 06:41:48 +00:00

20 lines
676 B
Bash

#!/bin/sh
XFLDNAME="-Bitstream-Bitstream Cyberbit-"
FONTNAME=cyberbit
FONTDIR=${PKG_PREFIX}/lib/X11/fonts/TrueType
if [ "$2" = "PRE-INSTALL" ]; then
echo "Please add ${FONTDIR} to your /etc/x11/xorg.conf file"
exit 0
fi
cd ${FONTDIR}
touch fonts.dir
sed -e "/${XFLDNAME}/d" fonts.dir > fonts.dir.tmp
numfonts=$(echo $(cat fonts.dir.tmp fonts.dir.${FONTNAME} | wc -l) - 2 | bc)
echo ${numfonts} > fonts.dir
sed -e 1d fonts.dir.tmp >> fonts.dir
sed -e 1d fonts.dir.$FONTNAME >> fonts.dir
touch fonts.alias
sed -e "/^${XFLDNAME}/d" fonts.alias > fonts.alias.tmp
mv -f fonts.alias.tmp fonts.alias
cat fonts.alias.${FONTNAME} >> fonts.alias
rm -f fonts.dir.tmp fonts.alias.tmp