# Pre-removal script 
# This script has been created for the purpose of
# restoring all VTS executables and objects that
# are overwritten by SUNWvtsst installation.
# Added By Scott Surguine
# Last Updated 08-21-00

# Define BASEDIR for SUNWvtsst directory

# to avoid a redundant slash
if [ "$BASEDIR" = '/' ]
then
      PDIR=''
else
      PDIR="$BASEDIR"
fi

echo "Processing 32 bit binaries..."
cd $PDIR/SUNWvts/bin

$PDIR/SUNWvts/bin/testrm tapetest 

if { pkginfo $iopts SUNWvtsx 1>/dev/null 2>&1 ; } then
   # do 64 bit version (ld works in both 32 and 64 bit modes correctly)
   echo "Processing 64 bit binaries..."
   cd $PDIR/SUNWvts/bin/sparcv9
   $PDIR/SUNWvts/bin/testrm tapetest 


else
   echo "Note: Processing 64 bit binaries was not done because of the below."
   echo "      The SUNWvtsx package is not installed.  This package is"
   echo "      required in order to process 64 bit binaries.  $PKG will"
   echo "      function normally in 32 bit mode.  If 64 bit support is needed,"
   echo "      then remove $PKG first and then add $PKG again after installing"
   echo "      the SUNWvtsx package."
fi

