# Copyright Sun Microsystems, Inc. All Rights Reserved.
# @(#)preremove	1.1	01/27/00

PATH=/bin:/usr/bin:/sbin:/usr/sbin

if [ -z "$PKG_INSTALL_ROOT" ]; then
  PKG_INSTALL_ROOT=""
fi

set -u

#
# Remove the Authentication Manager token directory
# and associated directories in tmp.
#

TARGDIR="$PKG_INSTALL_ROOT/var/opt/SUNWut/itokens"
TMPDIR="$PKG_INSTALL_ROOT/tmp/SUNWut/config"

if [ -h "$TARGDIR" ]
then
	/usr/bin/rm -f "$TARGDIR"
fi

for i in displays idle itokens tokens xconfig
do
        if [ -d "$TMPDIR/$i" ]
        then
                /bin/rm -rf "$TMPDIR/$i"
        fi
done
 
exit 0;
