an easy and consistent way of installing software ported to FreeBSD
#!/bin/sh
if [ "$2" != "DEINSTALL" ]; then
exit 0
fi
PKGNAME=$1
PREFIX=${PKG_PREFIX}
TTFM=${PKG_PREFIX}/bin/ttfm.sh
FONTDIR=${PREFIX}/share/fonts/TrueType
FONTS="simhei.ttf simsun.ttc tahoma.ttf"
if [ -r $FONTDIR/$PKGNAME ]; then
for i in `cat $FONTDIR/$PKGNAME`; do
for f in $FONTS; do
$TTFM --remove $i $f
done
done
fi
rm -f $FONTDIR/$PKGNAME
exit 0
Three TrueType fonts from Microsoft Windows(TM) 2000/XP.
Because of licensing restrictions, you must copy the three TrueType
fonts from your copy of Microsoft Windows(TM) 2000/XP manually. End
user can use these fonts freely in his/her own computers.
#!/bin/sh
if [ "$2" = "PRE-INSTALL" ]; then
exit 0
fi
PKGNAME=$1
PREFIX=${PKG_PREFIX}
TTFM=${PREFIX}/bin/ttfm.sh
FONTDIR=${PREFIX}/share/fonts/TrueType
FONTS="simhei.ttf simsun.ttc tahoma.ttf"
if [ ! -x $TTFM ]; then
echo "$TTFM not found!"
exit 1
fi
rm -f $FONTDIR/$PKGNAME
if [ "X$WITHOUT_X" = "X" ]; then
for f in $FONTS; do
$TTFM --add xttfm $FONTDIR/$f
done
echo "xttfm" >> $FONTDIR/$PKGNAME
fi
exit 0
share/fonts/TrueType/simhei.ttf
share/fonts/TrueType/simsun.ttc
share/fonts/TrueType/tahoma.ttf
@dirrmtry share/fonts/TrueType
@dirrmtry share/fonts