ac8071c50c
pkgsrc release engineering team. - Keep current directory with DEINSTALL and INSTALL script. - remove extra processing with POST-DEINSTALL action from DEINSTALL script. - Suggest use of additional graphic package. - Add APACHE_GROUP to BUILD_DEFS. - install ${GEEKLOG_EXAMPLESDIR}/createdb.php with INSTALL_SCRIPT. Bump PKGREVISION.
55 lines
1.5 KiB
Text
55 lines
1.5 KiB
Text
# $NetBSD: DEINSTALL,v 1.3 2006/07/23 13:21:09 taca Exp $
|
|
|
|
GEEKLOG_DIR="@GEEKLOG_DIR@"
|
|
GEEKLOG_EXAMPLESDIR="@GEEKLOG_EXAMPLESDIR@"
|
|
GEEKLOG_PUBDIR="@GEEKLOG_PUBDIR@"
|
|
GEEKLOG_TMPL_SUB="@GEEKLOG_TMPL_SUB@"
|
|
GEEKLOG_TMPL_DIR="@GEEKLOG_TMPL_DIR@"
|
|
|
|
case ${STAGE} in
|
|
DEINSTALL)
|
|
(cd ${GEEKLOG_TMPL_DIR}
|
|
${FIND} ${GEEKLOG_TMPL_SUB} -type f -print | \
|
|
while read f; do
|
|
file="${GEEKLOG_PUBDIR}/$f"
|
|
if ${TEST} -f ${file} -a -f ${f} && \
|
|
${CMP} -s ${file} ${f}; then
|
|
${RM} -f ${file}
|
|
fi
|
|
done
|
|
cd ${GEEKLOG_PUBDIR}
|
|
${FIND} -d ${GEEKLOG_TMPL_SUB} -type d -print |
|
|
while read d; do
|
|
${RMDIR} ${d} 2>/dev/null
|
|
done
|
|
# XXX: work around for remaining config.php and system/lib-custom.php
|
|
conf_files="${GEEKLOG_EXAMPLESDIR}/config.php \
|
|
${GEEKLOG_DIR}/config.php \
|
|
${GEEKLOG_EXAMPLESDIR}/system/lib-custom.php \
|
|
${GEEKLOG_DIR}/system/lib-custom.php"
|
|
file_list=
|
|
set ${conf_files}
|
|
while ${TEST} $# -gt 0; do
|
|
eg=$1; shift
|
|
cf=$1; shift
|
|
if ${TEST} -f ${cf} -a -f ${eg} && ${CMP} -s ${cf} ${eg}; then
|
|
${RM} ${cf}
|
|
else
|
|
file_list="${file_list} ${cf}"
|
|
fi
|
|
done
|
|
if ${TEST} -n "${file_list}"; then
|
|
${ECHO} "==========================================================================="
|
|
${ECHO} "The following files are no longer being used by ${PKGNAME},"
|
|
${ECHO} "and they can be removed if no other packages are using them:"
|
|
${ECHO} ""
|
|
for f in ${file_list}; do
|
|
${ECHO} " ${f}"
|
|
done
|
|
${ECHO} ""
|
|
${ECHO} "==========================================================================="
|
|
fi
|
|
)
|
|
;;
|
|
|
|
esac
|