blob: f43798383f48ec3cdce092d5529a9100a6d37ab7 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
|
#!/bin/sh
if [ "$2" != "DEINSTALL" ]; then
exit 0
fi
FONTDIR=${PKG_PREFIX}/lib/X11/fonts/local
FAFILE=${PKG_PREFIX}/share/doc/ja/k20fonts/fonts.alias
grepv() {
awk -v SRC=$1 'BEGIN{while (getline < SRC) {ENTRY[$0]=1}} (ENTRY[$0] != 1) {print}' $2
}
echo "Updating ${FONTDIR}/fonts.alias"
cd ${FONTDIR}
touch fonts.alias
cp fonts.alias fonts.alias.orig
grepv ${FAFILE} fonts.alias.orig > fonts.alias
if [ ! -s fonts.alias ]; then rm -f fonts.alias; fi
rm -f fonts.alias.orig
echo "**********************************************************"
echo "You should restart X server or do 'xset fp rehash' command"
echo "to enable this update."
echo "**********************************************************"
exit 0
|