← Back to Blog 0.7.0 · FS · FORGE

RUNE Container Reader — Forge ROM Distribution Format

June 23, 2026 · Sigil-Docs · sigil-fs 691b0d2
fsforgeretropie0.7.0

RUNE is the Sigil ROM distribution container for .ness, .sfcs, .gbc, .z64, etc. rune_read.sg provides the reader for the format: a simple header (magic + version + num_entries) followed by a directory (name_len + name + rom_size + rom_offset per entry) and ROM blobs. O(n) directory scan, name lookup, VFS-backed read. Supports up to 256 entries, 64 MB per ROM. ABCDE pass, 25/25 suite green.

RUNE container format

rune_read.sg
RUNE container readerrune_open(path): opens a .rune file, validates magic + version, reads num_entries from header. rune_directory_scan(): O(n) scan through the directory section — for each entry reads name_len, name (ROM filename), rom_size, rom_offset (byte offset into the RUNE file). rune_lookup(name): searches the directory for a ROM by name, returns its entry (size + offset). rune_read_rom(entry, buf): reads the ROM blob from the RUNE file into buf using VFS-backed read. Limits: up to 256 entries per container, 64 MB per individual ROM. Used by forgery_verify.sg to extract and verify ROMs before emulator launch. 25/25 tests PASS.