# HG changeset patch # User wenzelm # Date 1218886317 -7200 # Node ID 9a7f17370ffb68acd906b20cfd5d1c8450308baa # Parent c347986773eb97e971162561daa9324e80f5a35f refined scala/java wrappers via isatool; diff -r c347986773eb -r 9a7f17370ffb lib/Tools/browser --- a/lib/Tools/browser Sat Aug 16 13:31:56 2008 +0200 +++ b/lib/Tools/browser Sat Aug 16 13:31:57 2008 +0200 @@ -65,8 +65,7 @@ if [ -z "$GRAPHFILE" ]; then [ -d "$ISABELLE_BROWSER_INFO" ] && cd "$ISABELLE_BROWSER_INFO" - javawrapper GraphBrowser.GraphBrowser - RC="$?" + exec "$ISATOOL" java GraphBrowser.GraphBrowser else PRIVATE_FILE="${ISABELLE_TMP:-/tmp}/$$"$(basename "$GRAPHFILE") if [ -n "$CLEAN" ]; then @@ -84,9 +83,9 @@ esac if [ -z "$OUTFILE" ]; then - javawrapper GraphBrowser.GraphBrowser "$(jvmpath "$PRIVATE_FILE")" + "$ISATOOL" java GraphBrowser.GraphBrowser "$(jvmpath "$PRIVATE_FILE")" else - javawrapper GraphBrowser.Console "$(jvmpath "$PRIVATE_FILE")" "$(jvmpath "$OUTFILE")" + "$ISATOOL" java GraphBrowser.Console "$(jvmpath "$PRIVATE_FILE")" "$(jvmpath "$OUTFILE")" fi RC="$?" diff -r c347986773eb -r 9a7f17370ffb lib/Tools/java --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/lib/Tools/java Sat Aug 16 13:31:57 2008 +0200 @@ -0,0 +1,25 @@ +#!/usr/bin/env bash +# +# $Id$ +# Author: Makarius +# +# DESCRIPTION: Java wrapper + + +PRG="$(basename "$0")" + +function usage() +{ + echo + echo "Usage: $PRG [ARGS ...]" + echo + echo " Invoke Java within the Isabelle environment." + echo + exit 1 +} + + +## main + +CLASSPATH="$(jvmpath "$CLASSPATH")" +exec "$ISABELLE_JAVA" "$@" diff -r c347986773eb -r 9a7f17370ffb lib/Tools/scala --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/lib/Tools/scala Sat Aug 16 13:31:57 2008 +0200 @@ -0,0 +1,25 @@ +#!/usr/bin/env bash +# +# $Id$ +# Author: Makarius +# +# DESCRIPTION: Scala wrapper + + +PRG="$(basename "$0")" + +function usage() +{ + echo + echo "Usage: $PRG [ARGS ...]" + echo + echo " Invoke Scala within the Isabelle environment." + echo + exit 1 +} + + +## main + +CLASSPATH="$(jvmpath "$CLASSPATH")" +exec "$ISABELLE_SCALA" "$@" diff -r c347986773eb -r 9a7f17370ffb lib/scripts/getsettings --- a/lib/scripts/getsettings Sat Aug 16 13:31:56 2008 +0200 +++ b/lib/scripts/getsettings Sat Aug 16 13:31:57 2008 +0200 @@ -44,18 +44,13 @@ echo "$RESULT" } -#JVM path wrappers +#JVM path wrapper if [ "$OSTYPE" = cygwin ]; then CLASSPATH="$(cygpath -u -p "$CLASSPATH")" function jvmpath() { cygpath -w -p "$@"; } - function javawrapper() { env CLASSPATH="$(jvmpath "$CLASSPATH")" java "$@"; } - function scalawrapper() { env CLASSPATH="$(jvmpath "$CLASSPATH")" scala "$@"; } else function jvmpath() { echo "$@"; } - function javawrapper() { java "$@"; } - function scalawrapper() { scala "$@"; } fi -ISABELLE_HOME_JVM="$(jvmpath "$ISABELLE_HOME")" #CLASSPATH convenience function classpath () { @@ -87,6 +82,10 @@ ISABELLE_OUTPUT="$ISABELLE_OUTPUT/$ML_IDENTIFIER" +#JVM settings +ISABELLE_HOME_JVM="$(jvmpath "$ISABELLE_HOME")" +ISABELLE_HOME_USER_JVM="$(jvmpath "$ISABELLE_HOME_USER")" + set +o allexport fi