#!/bin/sh
#  $Id: linkJDK,v 1.9 1998/01/07 21:50:05 begolej Exp $
#test
 
PRG=$0
PROG_HOME=`dirname $PRG`
cd ${PROG_HOME}
PROG_HOME=`pwd`

if [ -z "$1" ] ; then
        REAL_JDK=${JDKHOME}
else
        REAL_JDK=$1
fi

if [ -z "${REAL_JDK}" ] ; then
	echo "usage: linkJDK <REAL_JDK_HOME>"
	echo "       where <REAL_JDK_HOME> is JDK installation root on this host"
	exit 1
fi

LINK_JDK=../jdk1.1-rJAMM

cd ${REAL_JDK}
REAL_JDK=`pwd`
cd ${PROG_HOME}

#echo Creating a linked version of JDK from $REAL_JDK to ${PROG_HOME}/${LINK_JDK}

rm -rf ${LINK_JDK}
mkdir -p ${LINK_JDK}
cd ${LINK_JDK}
echo Creating a linked version of JDK from $REAL_JDK to `pwd`
ln -s ${REAL_JDK}/* .
rm -f bin
rm -f lib
mkdir bin
cd bin
ln -s ${REAL_JDK}/bin/* .
cd ..
mkdir lib
cd lib
ln -s ${REAL_JDK}/lib/* .
rm -f awt.properties
cat ${REAL_JDK}/lib/awt.properties ../../config/awt.properties.append > awt.properties
#cp ../../config/awt.properties .
