#!/bin/sh
#
# browser-call script for the PROGRES-System.
#
# Initial version for the Upgrade system.  04/11/04 by mb.
#

#
# This file sets appropriate environment variables, creates an independant
# TMPGRAS directory, and starts the browser.
#

# Determine which operating system version the host has
osver=`uname -a`
case $osver in
SunOS*5.*)    # Solaris 2.x
        PLATFORM=sol2
        OSACCESSDIR=SOL2;;
SunOS*4.1.*)  # SunOS 4.1.x
        PLATFORM=sunos4
        OSACCESSDIR=SUNOS4;;
Linux*2.*.*)  # Linux 2.0.x
        PLATFORM=linuxlibc6
        OSACCESSDIR=LINUXLIBC6;;
*)      echo 'unknown os version' ;;  
esac
export PLATFORM OSACCESSDIR
 
UPGRADE2_ROOT=/home/projects/pro32/projects/upgrade2
export UPGRADE2_ROOT

UPGRADE2_DEVELOPER=true
export UPGRADE2_DEVELOPER

#
#
# Call the browser with PoolName and GraphName
# 

if [ -f $GRASBROWSERLOADPATH/bin/${OSACCESSDIR}/UpgradeBrowser ]
then
  echo
  echo "Invoking browser ... "
  $GRASBROWSERLOADPATH/bin/${OSACCESSDIR}/UpgradeBrowser --project=${PROJECT} --document=${1}
else
  echo
  echo "No Upgrade-Browser available!"
fi
