summaryrefslogtreecommitdiff
path: root/chinese/moettf/pkg-deinstall
diff options
context:
space:
mode:
authorJing-Tang Keith Jang <keith@FreeBSD.org>2000-12-09 20:09:35 +0000
committerJing-Tang Keith Jang <keith@FreeBSD.org>2000-12-09 20:09:35 +0000
commitde0cdb9f9e41cc092b33c46df94ce45ef26910ad (patch)
treea8e2d3b6ba0513c7d8b17cf4241516997719f494 /chinese/moettf/pkg-deinstall
parentUpdate to 1.0b10 (diff)
Adds two new fonts, moe_sungext.ttf and moe_sungsym.ttf. Although
the fonts are encoded in BIG5, the characters and symbols are from several less commonly used layers in CNS. See http://www.edu.tw/mandr/bbs/1-4-2/1-4-2.html for more details. Also displays messages about WANT_XX when installing.
Notes
Notes: svn path=/head/; revision=35809
Diffstat (limited to 'chinese/moettf/pkg-deinstall')
-rw-r--r--chinese/moettf/pkg-deinstall29
1 files changed, 18 insertions, 11 deletions
diff --git a/chinese/moettf/pkg-deinstall b/chinese/moettf/pkg-deinstall
index 8d161a41b09b..64fb4b8d3146 100644
--- a/chinese/moettf/pkg-deinstall
+++ b/chinese/moettf/pkg-deinstall
@@ -1,17 +1,24 @@
#!/bin/sh
+
if [ "$2" != "DEINSTALL" ]; then
exit 0
fi
-FONTDIR=${PKG_PREFIX}/lib/X11/fonts/TrueType
-cd ${FONTDIR}
-# Restore fonts.dir
-sed -e '/-moe-/d' -e '/-twmoe-/d' fonts.dir > fonts.dir.tmp
-numfonts=$(echo $(cat fonts.dir.tmp | wc -l) - 1 | bc)
-echo ${numfonts} > fonts.dir
-sed -e 1d fonts.dir.tmp >> fonts.dir
-rm -f fonts.dir.tmp
+PKGNAME=$1
+PREFIX=${PKG_PREFIX}
+TTFM=${PKG_PREFIX}/bin/ttfm.sh
+
+FONTDIR=${PREFIX}/share/fonts/TrueType
+FONTS="moe_lishu.ttf moe_kai.ttf moe_sung.ttf moe_sungext.ttf moe_sungsym.ttf"
+
+if [ -r $FONTDIR/$PKGNAME ]; then
+ for i in `cat $FONTDIR/$PKGNAME`; do
+ for f in $FONTS $DEFAULTMING $DEFAULTKAI; do
+ $TTFM --remove $i $f
+ done
+ done
+fi
+
+rm -f $FONTDIR/$PKGNAME
-# Restore fonts.alias
-sed -e '/^-moe-/d' -e '/^-twmoe-/d' fonts.alias > fonts.alias.tmp
-mv -f fonts.alias.tmp fonts.alias
+exit 0