1998-08-14 00:16:07 +00:00
|
|
|
#!/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%}
|
1998-11-11 14:33:02 +00:00
|
|
|
sitestartdir=${SITESTARTDIR:-%SITESTARTDIR%}
|
1998-08-14 00:16:07 +00:00
|
|
|
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
|
1998-11-20 18:19:10 +00:00
|
|
|
if [ X"${sitestartdir}" != X ] && \
|
|
|
|
[ "`grep \"^${OptionStart}\" ${sitestartdir}/site-start.el`" ]; then
|
1998-11-11 14:33:02 +00:00
|
|
|
${ECHO} "Deleting entry for \"${pkgname}\" from ${sitestartdir}/site-start.el"
|
1998-08-14 00:16:07 +00:00
|
|
|
${SED} -e "/^${OptionStart}/,/^${OptionEnd}/d" \
|
1998-11-11 14:33:02 +00:00
|
|
|
${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
|
1998-08-14 00:16:07 +00:00
|
|
|
fi
|
|
|
|
else
|
|
|
|
exit 0
|
|
|
|
fi
|