1
0
mirror of https://github.com/Interlisp/maiko.git synced 2026-01-13 15:18:14 +00:00
Nick Briggs c765ca5cc8
Update SDL dependent code and makefile segments to prepare for SDL3 (#497)
* Update SDL dependent code and makefile segments to prepare for SDL3

Many APIs have changed between SDL2 and SDL3.  This update adds
preprocessor conditionals to adapt the Maiko SDL code to allow selection of
the SDL major version (2 or 3) from the -DSDL=n define.

The SDL3 implementation is currently available as a preview release, 3.1.0, at
   https://github.com/libsdl-org/SDL/releases/tag/prerelease-3.1.0

* Add updates for makefile-haiku.x86_64-sdl to prepare for SDL3

* Allow makeright to accept sdl3 as display type to ease SDL3 experiments

* Update CMakeLists.txt for SDL3 library

 * Replaces configuration option -DMAIKO_DISPLAY_SDL=ON/OFF with
   -DMAIKO_DISPLAY_SDL=OFF/2/3
 * Replaces PUBLIC definitions with PRIVATE definitions on targets since
   we are not exporting definitions outside this local compilation
 * Update messages to indicate which version of SDL is being configured
 * Add fixup for SDL3.xcframework on macOS to compensate for missing
   RPATH specification (CMake issue 25998)
2024-05-21 12:07:13 -07:00
2024-04-10 20:14:46 -07:00
2020-12-29 11:00:24 -08:00

Maiko

Maiko is the implementation of the Medley Interlisp virtual machine, for a byte-coded Lisp instruction set and some low-level functions for connecting with Lisp for access to display (via X11) and disk etc.

For an overview, see Medley Interlisp Introduction.

See the Medley repository for

Bug reports, feature requests, fixes and improvements, support for additional platforms and hardware are all welcome.

Development Platforms

We are developing on FreeBSD, Linux, macOS, and Solaris currently on arm7l, arm64, PowerPC, SPARC, i386, and x86_64 hardware.

Building Maiko

Building requires clang, make, X11 client libraries (libx11-dev). For example,

$ sudo apt update
$ sudo apt install clang make libx11-dev
$ cd maiko/bin
$ ./makeright x
  • The build will (attempt to) detect the OS-type and cpu-type. It will build binaries lde and ldex in ../ostype.cputype (with .o files in ..ostype.cputype-x. For example, Linux on a 64-bit x86 will use linux.x86_64, while macOS 11 on a (new M1) Mac will use darwin.aarch64.
  • If you prefer using gcc over clang, you will need to edit the makefile fragment for your configuration (makefile-ostype.cputype-x) and comment out the line (with a #) that defines CC for clang and uncomment the line (delete the #) for the line that defines CC for gcc.
  • There is a cmake configuration (TBD To Be Described here).

Building For macOS

  • Running on macOS requires an X server, and building on a Mac requires X client libraries. An X-server for macOS (and X11 client libraries) can be freely obtained at https://www.xquartz.org/releases

Building for Windows 10

Windows 10 currently requires "Docker for Desktop" or WSL2 and a (Windows X-server). See Medley's README for more.

Languages
C 95.6%
Assembly 3.4%
CMake 0.5%
Shell 0.3%
sed 0.2%