diff options
author | FUJISHIMA Satsuki <sf@FreeBSD.org> | 2004-11-09 22:20:56 +0000 |
---|---|---|
committer | FUJISHIMA Satsuki <sf@FreeBSD.org> | 2004-11-09 22:20:56 +0000 |
commit | cb6ac0edad665d2b0fb742ae689535755c3c5ffa (patch) | |
tree | 2b2924cdeefff222e82e23f423efec42526f4380 /japanese/kappa20/pkg-req | |
parent | b000f92b14566ced1f44d527e39115e350171cdd (diff) | |
download | ports-cb6ac0edad665d2b0fb742ae689535755c3c5ffa.tar.gz ports-cb6ac0edad665d2b0fb742ae689535755c3c5ffa.zip |
Notes
Diffstat (limited to 'japanese/kappa20/pkg-req')
-rw-r--r-- | japanese/kappa20/pkg-req | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/japanese/kappa20/pkg-req b/japanese/kappa20/pkg-req index d856ce2bed1a..20532a9048c8 100644 --- a/japanese/kappa20/pkg-req +++ b/japanese/kappa20/pkg-req @@ -19,15 +19,18 @@ if [ "$2x" = "INSTALLx" -a ! -d ${FONTDIR} ]; then mkdir ${FONTDIR} fi +grepv() { + awk -v SRC=$1 'BEGIN{while (getline < SRC) {ENTRY[$0]=1}} (ENTRY[$0] != 1) {print}' $2 +} + if [ "$2" = "DEINSTALL" ] ; then - TMPFILE=/tmp/install-fonts-alias-$$ - cat ${PKG_PREFIX}/share/doc/ja/k20fonts/fonts.alias > ${TMPFILE} + FAFILE=${PKG_PREFIX}/share/doc/ja/k20fonts/fonts.alias echo "Updating ${FONTDIR}/fonts.alias" cd ${FONTDIR} touch fonts.alias cp fonts.alias fonts.alias.orig - grep -v -- "`cat ${TMPFILE}`" fonts.alias.orig > fonts.alias - rm -f fonts.alias.orig ${TMPFILE} + grepv ${FAFILE} fonts.alias.orig > fonts.alias + rm -f fonts.alias.orig fi echo "**********************************************************" |