sane environment defaults for Mac OS X, based on former App1/script -- e.g. relevant for MacTeX PATH;
--- a/Admin/MacOS/Info.plist-part2 Fri Jun 27 00:21:11 2014 +0100
+++ b/Admin/MacOS/Info.plist-part2 Fri Jun 27 11:30:42 2014 +0200
@@ -1,4 +1,5 @@
<string>-Disabelle.home=$APP_ROOT/Contents/Resources/{ISABELLE_NAME}</string>
+<string>-Disabelle.app=true</string>
</array>
<key>JVMArguments</key>
<array>
--- a/lib/scripts/getsettings Fri Jun 27 00:21:11 2014 +0100
+++ b/lib/scripts/getsettings Fri Jun 27 11:30:42 2014 +0200
@@ -16,6 +16,11 @@
function tar() { /usr/bin/gnutar "$@"; }
fi
+#sane environment defaults (notably on Mac OS X)
+if [ "$ISABELLE_APP" = true -a -x /usr/libexec/path_helper ]; then
+ eval $(/usr/libexec/path_helper -s)
+fi
+
#Cygwin vs. POSIX
if [ "$OSTYPE" = cygwin ]
then
--- a/src/Pure/System/isabelle_system.scala Fri Jun 27 00:21:11 2014 +0100
+++ b/src/Pure/System/isabelle_system.scala Fri Jun 27 11:30:42 2014 +0200
@@ -75,12 +75,22 @@
}
set_cygwin_root()
- val env0 = sys.env + ("ISABELLE_JDK_HOME" -> posix_path(jdk_home()))
+
+ val env =
+ {
+ val user_home = System.getProperty("user.home", "")
+ val isabelle_app = System.getProperty("isabelle.app", "")
- val user_home = System.getProperty("user.home", "")
- val env =
- if (user_home == "" || env0.isDefinedAt("HOME")) env0
- else env0 + ("HOME" -> user_home)
+ val env0 = sys.env + ("ISABELLE_JDK_HOME" -> posix_path(jdk_home()))
+ val env1 =
+ if (user_home == "" || env0.isDefinedAt("HOME")) env0
+ else env0 + ("HOME" -> user_home)
+ val env2 =
+ if (isabelle_app == "") env1
+ else env1 + ("ISABELLE_APP" -> "true")
+
+ env2
+ }
val system_home =
if (isabelle_home != null && isabelle_home != "") isabelle_home