2000-05-31 17:41:14 +00:00
|
|
|
#! /bin/sh
|
|
|
|
#
|
|
|
|
# Remove the ${PREFIX}/bin/tclsh script that gets installed by INSTALL.tclsh
|
|
|
|
# if we are the last tclsh installation to be pkg_delete'd.
|
|
|
|
#
|
|
|
|
# $FreeBSD$
|
|
|
|
#
|
|
|
|
|
|
|
|
#
|
|
|
|
# Explicitly listing /usr/X11R6/bin here is debatable.
|
|
|
|
#
|
|
|
|
BINDIR="${PKG_PREFIX}/bin /usr/X11R6/bin"
|
|
|
|
TCLSH=${PKG_PREFIX}/bin/tclsh
|
|
|
|
|
|
|
|
tclshs=$(/bin/ls ${BINDIR} 2> /dev/null | \
|
2000-05-31 18:31:17 +00:00
|
|
|
egrep '^(i?tclsh[0-9]+\.[0-9]+(\_r)?([a-z][a-z])?)|otclsh$')
|
2000-05-31 17:41:14 +00:00
|
|
|
|
|
|
|
if [ "$tclshs" = "" -a -f ${TCLSH} ] && \
|
|
|
|
(head -3 ${TCLSH} | grep awieYJFnsuILOnfsYEW) > /dev/null 2>&1
|
|
|
|
then
|
|
|
|
rm -f ${PKG_PREFIX}/bin/tclsh
|
|
|
|
fi
|