added ISABELLE_PLATFORM_FAMILY;
authorwenzelm
Sat, 24 Nov 2012 12:39:58 +0100
changeset 50182 30177ec0be36
parent 50181 bc3c4c89d5c9
child 50183 2b3e24e1c9e7
added ISABELLE_PLATFORM_FAMILY;
NEWS
lib/scripts/isabelle-platform
src/Doc/System/Basics.thy
--- a/NEWS	Fri Nov 23 23:07:58 2012 +0100
+++ b/NEWS	Sat Nov 24 12:39:58 2012 +0100
@@ -350,6 +350,9 @@
 settings manually, or use a Proof General version that has been
 bundled as Isabelle component.
 
+* Settings variable ISABELLE_PLATFORM_FAMILY refers to the general
+platform family: "linux", "macos", "windows".
+
 
 New in Isabelle2012 (May 2012)
 ------------------------------
--- a/lib/scripts/isabelle-platform	Fri Nov 23 23:07:58 2012 +0100
+++ b/lib/scripts/isabelle-platform	Sat Nov 24 12:39:58 2012 +0100
@@ -4,11 +4,13 @@
 #
 # NOTE: The ML system or JVM may have their own idea about the platform!
 
+ISABELLE_PLATFORM_FAMILY=""
 ISABELLE_PLATFORM32=""
 ISABELLE_PLATFORM64=""
 
 case $(uname -s) in
   Linux)
+    ISABELLE_PLATFORM_FAMILY="linux"
     case $(uname -m) in
       i?86)
         ISABELLE_PLATFORM32=x86-linux
@@ -20,6 +22,7 @@
     esac
     ;;
   Darwin)
+    ISABELLE_PLATFORM_FAMILY="macos"
     case $(uname -m) in
       i?86)
         ISABELLE_PLATFORM32=x86-darwin
@@ -34,6 +37,7 @@
     esac
     ;;
   CYGWIN_NT*)
+    ISABELLE_PLATFORM_FAMILY="windows"
     case $(uname -m) in
       i?86 | x86_64)
         ISABELLE_PLATFORM32=x86-cygwin
@@ -41,6 +45,7 @@
     esac
     ;;
   *BSD)
+    ISABELLE_PLATFORM_FAMILY="linux"
     case $(uname -m) in
       i?86 | x86_64)
         ISABELLE_PLATFORM32=x86-linux  #cf. BSD Linux Binary Compatibility
--- a/src/Doc/System/Basics.thy	Fri Nov 23 23:07:58 2012 +0100
+++ b/src/Doc/System/Basics.thy	Sat Nov 24 12:39:58 2012 +0100
@@ -172,7 +172,14 @@
   @{setting ISABELLE_HOME} to some extend. In particular, site-wide
   defaults may be overridden by a private @{verbatim
   "$ISABELLE_HOME_USER/etc/settings"}.
-  
+
+  \item[@{setting_def ISABELLE_PLATFORM_FAMILY}@{text "\<^sup>*"}] is
+  automatically set to the general platform family: @{verbatim linux},
+  @{verbatim macos}, @{verbatim windows}.  Note that
+  platform-dependent tools usually need to refer to the more specific
+  identification according to @{setting ISABELLE_PLATFORM}, @{setting
+  ISABELLE_PLATFORM32}, @{setting ISABELLE_PLATFORM64}.
+
   \item[@{setting_def ISABELLE_PLATFORM}@{text "\<^sup>*"}] is automatically
   set to a symbolic identifier for the underlying hardware and
   operating system.  The Isabelle platform identification always