#
# ident "@(#)postinstall.src	1.8 02/11/19 SMI"
#
# Copyright 2000-2002 Sun Microsystems, Inc.  All rights reserved.
#

BASEDIR=`/usr/bin/pkgparam SUNWutesa BASEDIR`

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

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

set -u

#
# Copy the services table if it doesn't exist
#

if [ -d /etc/opt/SUNWut ]; then
  cp ${PKG_INSTALL_ROOT}${BASEDIR}/SUNWut/etc/template/utsservices.cfg \
	/etc/opt/SUNWut/utsservices.cfg
fi

#
# Add the SunMC agent links to the files just installed if SunMC is installed
#
${PKG_INSTALL_ROOT}${BASEDIR}/SUNWut/lib/utsunmcagent -f

exit 0;
