#!/bin/sh

#	
#	Attempt to dig out installation directory
#	of the BASE package
#
umask 022

#TOPDIR=`pkgparam HPXT-BASE TOPDIR`
. /usr/bin/X11/700X/admin/env.vars

if [ $? -ne 0 -o ! -d "$TOPDIR" ]
then
  echo "ERROR:   Could not locate installation directory of HPXT-BASE package."
  echo "ERROR:   This package must be installed before other packages"
  exit 1
fi

ADMINDIR=$TOPDIR/usr/bin/X11/700X/admin
. $ADMINDIR/env.vars


if [ "$OS" = "sun5" ]
then
  echo
  echo "Installation will be finished shortly."
  echo "To configure your X terminals, you should then run"
  echo "$ADMINDIR/xtadm"
  echo "Installation will be finished shorly."
  echo $NL1 "Enter <return> to continue: $NL2" 
  read ANS
  echo
fi

echo TOPDIR=$TOPDIR 		> $1

exit 0
