equal
deleted
inserted
replaced
246 } |
246 } |
247 |
247 |
248 |
248 |
249 /* Isabelle application script */ |
249 /* Isabelle application script */ |
250 |
250 |
251 def make_isabelle_app(path: Path, classpath: List[Path], jdk_component: String) |
251 def make_isabelle_app( |
|
252 path: Path, |
|
253 isabelle_home_prefix: String, |
|
254 jdk_component: String, |
|
255 classpath: List[Path]) |
252 { |
256 { |
253 val script = """#!/usr/bin/env bash |
257 val script = """#!/usr/bin/env bash |
254 # |
258 # |
255 # Author: Makarius |
259 # Author: Makarius |
256 # |
260 # |
257 # Main Isabelle application script. |
261 # Main Isabelle application script. |
258 |
262 |
259 # minimal Isabelle environment |
263 # minimal Isabelle environment |
260 |
264 |
261 ISABELLE_HOME="$(cd "$(dirname "$0")"; cd "$(pwd -P)/../.."; pwd)" |
265 ISABELLE_HOME="$(cd "$(dirname "$0")"; cd "$(pwd -P)""" + isabelle_home_prefix + """"; pwd)" |
262 source "$ISABELLE_HOME/lib/scripts/isabelle-platform" |
266 source "$ISABELLE_HOME/lib/scripts/isabelle-platform" |
263 |
267 |
264 #paranoia settings -- avoid intrusion of alien options |
268 #paranoia settings -- avoid intrusion of alien options |
265 unset "_JAVA_OPTIONS" |
269 unset "_JAVA_OPTIONS" |
266 unset "JAVA_TOOL_OPTIONS" |
270 unset "JAVA_TOOL_OPTIONS" |
550 File.write(isabelle_target + Path.explode("Isabelle.options"), |
554 File.write(isabelle_target + Path.explode("Isabelle.options"), |
551 terminate_lines(java_options_title :: java_options)) |
555 terminate_lines(java_options_title :: java_options)) |
552 |
556 |
553 make_isabelle_app( |
557 make_isabelle_app( |
554 isabelle_target + Path.explode("lib/scripts/Isabelle_app"), |
558 isabelle_target + Path.explode("lib/scripts/Isabelle_app"), |
555 classpath, jdk_component) |
559 "/../..", jdk_component, classpath) |
556 |
560 |
557 val linux_app = isabelle_target + Path.explode("contrib/linux_app") |
561 val linux_app = isabelle_target + Path.explode("contrib/linux_app") |
558 File.move(linux_app + Path.explode("Isabelle"), |
562 File.move(linux_app + Path.explode("Isabelle"), |
559 isabelle_target + Path.explode(isabelle_name)) |
563 isabelle_target + Path.explode(isabelle_name)) |
560 Isabelle_System.rm_tree(linux_app) |
564 Isabelle_System.rm_tree(linux_app) |