#!@SHELL@
applet_name=fr.esrf.logviewer.Main

if [ ! $TANGO_HOST ] && [ -f @TANGO_RC_FILE@ ]; then
   . @TANGO_RC_FILE@
fi

#
# Define the CLASSPATH
#
JAVALIB=@prefix@/share/java;
JAVABIN=@prefix@/share/java;
ATKBIN=@prefix@/share/java;
TLVBIN=@prefix@/share/java;

ATKJAR=$ATKBIN/ATKCore.jar:$ATKBIN/ATKWidget.jar:$ATKBIN/log4j.jar

CLASSPATH=$JAVALIB/JTango.jar:$TLVBIN/LogViewer.jar:$ATKJAR:.
export CLASSPATH

LOGBACK=${TANGO_LOGBACK:-@prefix@/share/tango/logback.xml}

@JAVA@ \
    -DTANGO_HOST=$TANGO_HOST \
    -Dlogback.configurationFile="$LOGBACK" \
    $applet_name \
    "$@"
