author | wenzelm |
Sat, 14 Oct 2023 15:16:40 +0200 | |
changeset 78773 | 9198e785d3d7 |
parent 78771 | d7f4c5c7bebb |
child 78777 | 3b424f9cd5eb |
permissions | -rw-r--r-- |
64339 | 1 |
Multi-platform support of Isabelle |
2 |
================================== |
|
35610 | 3 |
|
4 |
Preamble |
|
5 |
-------- |
|
6 |
||
7 |
The general programming model is that of a stylized ML + Scala + POSIX |
|
68002 | 8 |
environment, with a minimum of system-specific code in user-space |
9 |
tools. |
|
35610 | 10 |
|
67235 | 11 |
The Isabelle system infrastructure provides some facilities to make |
12 |
this work, e.g. see the ML and Scala modules File and Path, or |
|
48833 | 13 |
functions like Isabelle_System.bash. The settings environment also |
61294 | 14 |
provides some means for portability, e.g. the bash function |
15 |
"platform_path" to keep the impression that Windows/Cygwin adheres to |
|
73646 | 16 |
Isabelle/POSIX standards, although many executables are native on |
17 |
Windows (notably Poly/ML and Java). |
|
35610 | 18 |
|
19 |
When producing add-on tools, it is important to stay within this clean |
|
67235 | 20 |
room of Isabelle, and refrain from non-portable access to operating |
73646 | 21 |
system functions. The Isabelle environment uses GNU bash and |
22 |
Isabelle/Scala as portable system infrastructure, using somewhat |
|
23 |
peculiar implementation techniques. |
|
35610 | 24 |
|
25 |
||
26 |
Supported platforms |
|
27 |
------------------- |
|
28 |
||
72366 | 29 |
A broad range of hardware and operating system platforms are supported |
30 |
by building executables on base-line versions that are neither too old |
|
73646 | 31 |
nor too new. Common OS families should work: Linux, macOS, |
32 |
Windows. More exotic platforms are unsupported: NixOS, BSD, Solaris. |
|
72366 | 33 |
|
73646 | 34 |
Official platforms: |
35610 | 35 |
|
78773 | 36 |
x86_64-linux Ubuntu 18.04 LTS |
35610 | 37 |
|
72366 | 38 |
x86_64-darwin macOS 10.13 High Sierra (lapbroy68 MacBookPro11,2) |
78771
d7f4c5c7bebb
more platform tests: initial support for macOS 14 Sonoma;
wenzelm
parents:
78743
diff
changeset
|
39 |
macOS 10.14 Mojave (???) |
76027 | 40 |
macOS 10.15 Catalina (???) |
74063
ff466b272267
clarified version: Apple now counts like 11, 12, ...;
wenzelm
parents:
73646
diff
changeset
|
41 |
macOS 11 Big Sur (mini1 Macmini8,1) |
76027 | 42 |
macOS 12 Monterey (laramac01 Macmini8,1) |
78484 | 43 |
macOS 13 Ventura (mini3 Mac14,12 -- MacMini M2 Pro, 6+4 cores) |
78771
d7f4c5c7bebb
more platform tests: initial support for macOS 14 Sonoma;
wenzelm
parents:
78743
diff
changeset
|
44 |
macOS 14 Sonoma (mini2 Macmini8,1) |
72366 | 45 |
|
78484 | 46 |
arm64-darwin macOS 11 Big Sur (assur Macmini9,1 -- MacMini M1, 4+4 cores) |
76375
089e546f671f
more macOS platforms, without reference hardware;
wenzelm
parents:
76028
diff
changeset
|
47 |
macOS 12 Monterey (???) |
78484 | 48 |
macOS 13 Ventura (mini3 Mac14,12 -- MacMini M2 Pro, 6+4 cores) |
78771
d7f4c5c7bebb
more platform tests: initial support for macOS 14 Sonoma;
wenzelm
parents:
78743
diff
changeset
|
49 |
macOS 14 Sonoma (studio1 Mac13,2 M1 Ultra, 16+4 cores) |
73646 | 50 |
|
72526 | 51 |
x86_64-windows Windows 10 |
78304
e4b57eea7f86
update cygwin for Isabelle2023 -- somewhere after cygwin 3.4.0-1 (see https://cygwin.com/pipermail/cygwin-announce/2022-December/010821.html);
wenzelm
parents:
78144
diff
changeset
|
52 |
x86_64-cygwin Cygwin 3.4.x https://isabelle.sketis.net/cygwin_2023 (x86_64/release) |
72366 | 53 |
|
73646 | 54 |
Experimental platforms: |
72359 | 55 |
|
72371
3e84f4e9651a
clarified arm64-linux base line: prefer Pi OS, which is based on slightly older Debian;
wenzelm
parents:
72366
diff
changeset
|
56 |
arm64-linux Raspberry Pi OS 64bit beta (Debian 10 / Buster) |
36204 | 57 |
|
58 |
||
66911 | 59 |
64 bit vs. 32 bit platform personality |
60 |
-------------------------------------- |
|
36204 | 61 |
|
67235 | 62 |
Isabelle requires 64 bit hardware running a 64 bit operating |
72895 | 63 |
system. Only Windows still supports native x86 executables, but the |
64 |
POSIX emulation on Windows via Cygwin64 works exclusively for x86_64. |
|
65073 | 65 |
|
72895 | 66 |
The Isabelle settings environment provides variable |
67 |
ISABELLE_PLATFORM64 to refer to the standard platform personality. On |
|
68 |
Windows this is for Cygwin64, but the following native platform |
|
69 |
identifiers are available as well: |
|
65073 | 70 |
|
66732 | 71 |
ISABELLE_WINDOWS_PLATFORM64 |
65073 | 72 |
ISABELLE_WINDOWS_PLATFORM32 |
73 |
||
72894
bd2269b6cd99
updated "macOS" terminology: current Big Sur is already version 11;
wenzelm
parents:
72526
diff
changeset
|
74 |
These are always empty on Linux and macOS, and non-empty on |
72895 | 75 |
Windows. For example, this is how to refer to native Windows and |
76 |
fall-back on Unix (always 64 bit): |
|
77 |
||
78 |
"${ISABELLE_WINDOWS_PLATFORM64:-$ISABELLE_PLATFORM64}" |
|
65073 | 79 |
|
72895 | 80 |
And this is for old 32 bit executables on Windows, but still 64 bit on |
81 |
Unix: |
|
82 |
||
83 |
"${ISABELLE_WINDOWS_PLATFORM32:-$ISABELLE_PLATFORM64}" |
|
65073 | 84 |
|
73646 | 85 |
For Apple Silicon the native platform is "$ISABELLE_APPLE_PLATFORM64" |
86 |
(arm64-darwin), but thanks to Rosetta 2 "$ISABELLE_PLATFORM64" |
|
87 |
(x64_64-darwin) works routinely with fairly good performance. |
|
88 |
||
65073 | 89 |
|
35610 | 90 |
Dependable system tools |
91 |
----------------------- |
|
92 |
||
93 |
The following portable system tools can be taken for granted: |
|
94 |
||
73646 | 95 |
* Scala on top of Java. Isabelle/Scala irons out many fine points of |
96 |
the Java platform to make it fully portable as described above. |
|
64339 | 97 |
|
68002 | 98 |
* GNU bash as uniform shell on all platforms. The POSIX "standard" |
99 |
shell /bin/sh does *not* work portably -- there are too many |
|
100 |
non-standard implementations of it. On Debian and Ubuntu /bin/sh is |
|
101 |
actually /bin/dash and introduces many oddities. |
|
35610 | 102 |
|
103 |
||
104 |
Known problems |
|
105 |
-------------- |
|
106 |
||
73646 | 107 |
* macOS: If Homebrew or MacPorts is installed, there is some danger |
108 |
that accidental references to its shared libraries are created |
|
41668 | 109 |
(e.g. libgmp). Use otool -L to check if compiled binaries also work |
110 |
without MacPorts. |
|
111 |
||
55438 | 112 |
* Common Unix tools like /bin/sh, /bin/kill, sed, ulimit are |
64339 | 113 |
notoriously non-portable an should be avoided. |
66911 | 114 |
|
73646 | 115 |
* The traditional "uname" Unix tool only tells about its own |
116 |
executable format, not the underlying platform! |