How fuerchter/rayman-ps1-decomp works
Main components
a. External Input
• PS1 Game Disc Image (SLUS-000.05)
b. Extraction & Data Layer
• mk-splat build scripts (mk-splat.mk, mk-nugget.mk)
• splat tool (extracts segments into src/data and include/data headers)
c. Source Code Modules
• Header files (include/) matching each module
• src/data/* (auto-extracted data C files)
d. Decompilation & Matching Tools
• m2c, m2ctx.py, maspsx, asm-differ, decomp-permuter, permuter_settings.toml
• diff_settings.py (configures matching rules)
e. Build Toolchain
• PSX cross-compiler (gcc-2.5.7 cc1 under tools/gcc-2.5.7/)
• cpp-mipsel-linux-gnu / binutils-mipsel-linux-gnu
• psyq libraries (tools/psyq-3.0-converted)
f. Linker & Packaging
• Link object files into final PSX executable (.exe/EXE)
• Embed headers, data segments, produce binary matching original CRC
g. Continuous Integration
• .github/workflows/build.yml (GitHub Actions to run make, sha1 check)
Relationships and data flows
– Tools inspect compiled objects vs original ASM to drive matching
Architectural/design principles
• Modular partitioning by game subsystem (collision, rendering, input, audio, world)
• Data-driven decompilation: raw binary segments → auto-gen data C → build
• Iterative compile-compare cycle with decomp tools until match
• Separation of concerns:
– Extraction layer vs source layer vs decomp-tool layer vs build layer
Call out key technologies
• PSX cross-compilation (gcc-2.5.7, psyq)
• splat for extraction/repacking
• m2c & m2ctx for context-based C generation
• asm-differ & decomp-permuter for diff-based matching
• GitHub Actions for CI