lib/Tools/scalac
author wenzelm
Thu, 12 Apr 2012 23:03:25 +0200
changeset 47441 2fa904af222f
parent 47115 1a05adae1cc9
child 47748 24550210de0b
permissions -rwxr-xr-x
direct scala toplevel tools to ISABELLE_JDK_HOME;
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
44950
f60405791a1d added "isabelle scalac" convenience;
wenzelm
parents:
diff changeset
     1
#!/usr/bin/env bash
f60405791a1d added "isabelle scalac" convenience;
wenzelm
parents:
diff changeset
     2
#
f60405791a1d added "isabelle scalac" convenience;
wenzelm
parents:
diff changeset
     3
# Author: Makarius
f60405791a1d added "isabelle scalac" convenience;
wenzelm
parents:
diff changeset
     4
#
f60405791a1d added "isabelle scalac" convenience;
wenzelm
parents:
diff changeset
     5
# DESCRIPTION: invoke Scala compiler within the Isabelle environment
f60405791a1d added "isabelle scalac" convenience;
wenzelm
parents:
diff changeset
     6
f60405791a1d added "isabelle scalac" convenience;
wenzelm
parents:
diff changeset
     7
[ -e "$ISABELLE_HOME/Admin/build" ] && { "$ISABELLE_HOME/Admin/build" jars || exit $?; }
f60405791a1d added "isabelle scalac" convenience;
wenzelm
parents:
diff changeset
     8
47441
2fa904af222f direct scala toplevel tools to ISABELLE_JDK_HOME;
wenzelm
parents: 47115
diff changeset
     9
export JAVA_HOME="$ISABELLE_JDK_HOME"
2fa904af222f direct scala toplevel tools to ISABELLE_JDK_HOME;
wenzelm
parents: 47115
diff changeset
    10
44950
f60405791a1d added "isabelle scalac" convenience;
wenzelm
parents:
diff changeset
    11
CLASSPATH="$(jvmpath "$CLASSPATH")"
47115
1a05adae1cc9 more robust command invocation via ISABELLE_JDK_HOME or SCALA_HOME (NB: bash exec requires genuine executable, not function);
wenzelm
parents: 45385
diff changeset
    12
isabelle_scala scalac -Dfile.encoding=UTF-8 \
45385
7c1375ba1424 offline build of java_ext_dirs.jar, to avoid runtime dependency on javac/jar executables;
wenzelm
parents: 44950
diff changeset
    13
  "-Djava.ext.dirs=$("$ISABELLE_HOME/src/Tools/JVM/java_ext_dirs")" "$@"