1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
//! High-Level Emulation (HLE) for classic Macintosh applications.
//!
//! `systemless` runs Mac OS Toolbox apps without a real ROM by intercepting
//! 68k A-line trap instructions (`$A000`–`$AFFF`) and dispatching them
//! to native Rust handlers — the QuickDraw, Window Manager, Resource
//! Manager, Sound Manager, SANE, and the rest of the Toolbox are
//! reimplemented natively. The 68k CPU itself is interpreted by the
//! [`m68k`] crate.
//!
//! See the crate's `README.md` for the architecture overview.
//!
//! # Quick start
//!
//! ```no_run
//! use systemless::runner::{FixtureRunner, FixtureRunnerConfig};
//!
//! // Allocate an 8 MiB guest, default config (kiosk mode — Mac menu
//! // bar suppressed; arrow keys not remapped to numpad).
//! let config = FixtureRunnerConfig::default();
//! let mut runner = FixtureRunner::new(8 * 1024 * 1024, config);
//!
//! // Load a Mac executable (StuffIt archive, MacBinary, or raw
//! // resource fork — the loader auto-detects the format).
//! let bytes = std::fs::read("MyGame.sit").unwrap();
//! let _app = systemless::game::load_game(&mut runner, &bytes).unwrap();
//!
//! // Step the guest until it halts or the budget runs out.
//! // The bool is `still_running` — false means the CPU halted.
//! let (steps_taken, still_running) = runner.run_steps(100_000, None);
//! println!("ran {} steps, still_running = {}", steps_taken, still_running);
//! ```
//!
//! [`m68k`]: https://crates.io/crates/m68k
pub use ;