home *** CD-ROM | disk | FTP | other *** search
/ PC World 2001 March / PCWorld_2001-03_cd.bin / Software / Komercni / VAgeJava / ivj35 / setup / UPDATE.Cab / F17712_runnit < prev    next >
Text File  |  2000-07-30  |  953b  |  37 lines

  1. #!/bin/sh
  2. #
  3. # %% %%
  4.  
  5. if [ -z "${JAVA_HOME}" ] ; then
  6.     if [ -d /usr/local/java/jdk1.1.6/solaris ] ; then
  7.         JAVA_HOME=/usr/local/java/jdk1.1.6/solaris
  8.     CLASSPATH=.:/usr/local/java/jdk1.1.6/solaris/lib/classes.zip
  9.     export CLASSPATH
  10.     else
  11.         echo "JAVA_HOME environment variable not set." 1>&2 
  12.         exit 1
  13.     fi
  14. fi
  15.  
  16. # Compute an absolute pathname here because Class.getResource()
  17. # fails if $CLASSPATH contains "../".
  18. if [ -d ../../1.1_demo ] ; then
  19.     SWING_HOME=`(cd ../../1.1_classes; pwd)`
  20.     SWING_JARS=${SWING_HOME}
  21. else
  22.     SWING_HOME=`(cd ../../; pwd)`
  23.     SWING_JARS=${SWING_HOME}/swing.jar:${SWING_HOME}/motif.jar:${SWING_HOME}/multi.jar:${SWING_HOME}/windows.jar
  24. fi
  25.  
  26. SWING_CLASSES=.:${SWING_JARS}
  27. if [ -z "$CLASSPATH" ] ; then
  28.     CLASSPATH="${SWING_CLASSES}":${JAVA_HOME}/lib/classes.zip
  29. else
  30.     CLASSPATH="${SWING_CLASSES}:$CLASSPATH"
  31. fi
  32.  
  33. CMD="${JAVA_HOME}/bin/java -classpath ${CLASSPATH} Notepad"
  34.  
  35. echo ${CMD}
  36. ${CMD}
  37.