Case study

Castlevania: Symphony of the Night: matching decompilation across PlayStation, PSP and Saturn builds

Recreates C source for Castlevania: Symphony of the Night from its PlayStation, PSP and Saturn binaries, aiming for code that compiles byte for byte to the original game files. The work-in-progress build combines decompiled code with assets and assembly extracted from a user-supplied disc image, then checks per-version SHA-1 hashes. Native PC experiments in the same tree are documented as unfinished and are not a released port.

Requirements and limitations

  • README describes a work-in-progress matching decompilation of four builds: us (PlayStation SLUS-00067, the reference), hd (an unreleased Japanese PS1 build found in Castlevania: Dracula X Chronicles data), pspeu (the European Dracula X Chronicles release) and saturn (the externally developed Saturn port). The Build wiki notes that some non-matching functions remain behind a NON_MATCHING macro and are not guaranteed to be functionally equivalent. README links mutable progress pages on sotn.xee.dev and decomp.dev; this collection recorded no completion figure.
  • The repository includes no game assets and none of the assembly needed to compile; README requires a prior copy of the game. The Build wiki asks for an unmodified US PlayStation disc as BIN/CUE, while the pinned Makefile reads both PSP-derived builds from a European Dracula X Chronicles ISO and the Saturn build from a Saturn BIN/CUE, each placed under disks/ with a version-specific name.
  • The Build wiki is tested against Ubuntu 24.04 LTS in CI and also covers Windows through WSL 2 and Arch-based distributions; a Dockerfile provides an Ubuntu Noble environment. Builds need Go, Rust, Python 3.12+, MIPS and SH binutils, a MIPS GCC, ninja and submodule tools such as m2c, maspsx, asm-differ, mipsmatch and decomp-permuter. Project-hosted prebuilt archives, including cc1-psx, mwccpsp, a Cygnus 2.7 toolchain and wibo, are checked against SHA-256 files; the Saturn build also uses dosemu.
  • Unless SKIP_CHECK is set, the pinned build code hashes its outputs against config/check.<version>.sha, which lists main.exe, DRA.BIN, RIC.BIN and stage and overlay files for us and shorter lists for hd, pspeu and saturn. The wiki still names a make check step that the pinned Makefile does not define. These checks compare file identity for the supplied version, not gameplay coverage, and this collection did not rerun them.
  • The Makefile also accepts a pc version and src/pc holds native-port code, but the PC Port wiki page says no working end-to-end port based on the decompilation exists yet; no PC port is claimed here. The repository declares AGPL-3.0, while disc images, extracted assets and assembly, and the downloaded compilers keep separate rights. CONTRIBUTING allows coding-agent assistance only for changes contributors can justify and operate manually and requires commits and pull requests without autonomous tooling; this establishes no REA use, and no runtime reproduction is claimed.

About this entry

Type
Case study
Category
Independent reconstruction cases
Relationship
Independent reconstruction project
Targets
Game

Sources reviewed

The description was reviewed against primary sources. This does not establish runtime testing, security auditing or verified compatibility.

Primary sources

  1. README.md GitHub · Xeeynamo/sotn-decomp · Revision eddaf22
  2. Makefile GitHub · Xeeynamo/sotn-decomp · Revision eddaf22
  3. LICENSE GitHub · Xeeynamo/sotn-decomp · Revision eddaf22
  4. CONTRIBUTING.md GitHub · Xeeynamo/sotn-decomp · Revision eddaf22
  5. .gitmodules GitHub · Xeeynamo/sotn-decomp · Revision eddaf22
  6. Dockerfile GitHub · Xeeynamo/sotn-decomp · Revision eddaf22
  7. disks/README GitHub · Xeeynamo/sotn-decomp · Revision eddaf22
  8. tools/requirements-debian.txt GitHub · Xeeynamo/sotn-decomp · Revision eddaf22
  9. tools/sotn-assets/build.go GitHub · Xeeynamo/sotn-decomp · Revision eddaf22
  10. tools/sotn-assets/check.go GitHub · Xeeynamo/sotn-decomp · Revision eddaf22
  11. config/check.us.sha GitHub · Xeeynamo/sotn-decomp · Revision eddaf22
  12. config/check.hd.sha GitHub · Xeeynamo/sotn-decomp · Revision eddaf22
  13. config/check.pspeu.sha GitHub · Xeeynamo/sotn-decomp · Revision eddaf22
  14. config/check.saturn.sha GitHub · Xeeynamo/sotn-decomp · Revision eddaf22
  15. https://github.com/Xeeynamo/sotn-decomp/wiki/Build
  16. https://github.com/Xeeynamo/sotn-decomp/wiki/PC-Port