1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-11-01 22:05:08 +00:00
freebsd-ports/print/yatex/files/DEINSTALL.tmpl
Jun Kuriyama 9ad2e50ef4 Install directory is changed.
PR:		ports/8224
Submitted by:	Satoshi Taoka <taoka@infonets.hiroshima-u.ac.jp>
1998-11-11 14:33:02 +00:00

34 lines
1009 B
Bash

#!/bin/sh
pkgname=$1
CP=${CP:-%CP%}
ECHO=${ECHO:-%ECHO%}
GREP=${GREP:-%GREP%}
RM=${RM:-%RM%}
SED=${SED:-%SED%}
infodir=${INFODIR:-%INFODIR%}
infofiles=${INFOFILES:-%INFOFILES%}
sitestartdir=${SITESTARTDIR:-%SITESTARTDIR%}
elispdir=${ELISPDIR:-%ELISPDIR%}
OptionStart=";;; configuration options for ${pkgname}"
OptionEnd=";;; End of configuration options for ${pkgname}"
if [ "X$2" = X"DEINSTALL" ]; then
${ECHO} "Deleting entry for \"${pkgname}\" from ${infodir}/dir"
for file in `echo ${infofiles} | ${SED} "s,:, ,g"`; do
install-info --delete ${infodir}/${file} ${infodir}/dir
done
if [ "`grep \"^${OptionStart}\" ${sitestartdir}/site-start.el`" ]; then
${ECHO} "Deleting entry for \"${pkgname}\" from ${sitestartdir}/site-start.el"
${SED} -e "/^${OptionStart}/,/^${OptionEnd}/d" \
${sitestartdir}/site-start.el > ${sitestartdir}/site-start.el.bak
${CP} ${sitestartdir}/site-start.el.bak ${sitestartdir}/site-start.el
${RM} ${sitestartdir}/site-start.el.bak
fi
else
exit 0
fi