Admin/Linux/Isabelle
author wenzelm
Thu, 12 Sep 2013 15:37:09 +0200
changeset 53581 c0ad478abf50
parent 53573 3cffcc303fc0
child 54037 ab77ec347220
permissions -rw-r--r--
generate distribution classpath for cold-start application wrappers;

#!/usr/bin/env bash
#
# Author: Makarius
#
# Main Isabelle application wrapper.

# dereference executable
if [ -L "$0" ]; then
  TARGET="$(LC_ALL=C ls -l "$0" | sed 's/.* -> //')"
  exec "$(cd "$(dirname "$0")"; cd "$(pwd -P)"; cd "$(dirname "$TARGET")"; pwd)/$(basename "$TARGET")" "$@"
fi


# minimal Isabelle environment

ISABELLE_HOME="$(cd "$(dirname "$0")"; cd "$(pwd -P)"; pwd)"
source "$ISABELLE_HOME/lib/scripts/isabelle-platform"


# main

exec "$ISABELLE_HOME/contrib/jdk/${ISABELLE_PLATFORM64:-$ISABELLE_PLATFORM32}/bin/java" \
  "-Disabelle.home=$ISABELLE_HOME" \
  {JAVA_ARGS} \
  -classpath "{CLASSPATH}" \
  isabelle.Main "$@"