Skip to content
PORTSNATIVE.
HomeCatalog
Web GamesEmulatorsToolsNews
PORTSNATIVE.

A catalog for discovering ports and related projects. We link to official sources and do not host original game files.

ExploreCatalogMy list
InformationAbout usSuggest a portSupportDonationsLegal notice
© 2026 PortsNative
Back to catalog
Mega Man X4
PORTSNATIVE

Mega Man X4

NATIVE PORTPLATFORMERWINDOWSALPHA

Mega Man X4

TechnologyNative C/C++ port (engine reimplementation)

Available forWindows

View official project

About the project

Mega Man X4, conocido como Rockman X4 en Japón, es el cuarto juego de la serie Mega Man X. Este juego fue lanzado originalmente el 1 de agosto de 1997 en Japón para las consolas Sega Saturn y PlayStation. Fue lanzado en Norteamérica en septiembre de 1997[cita requerida] para ambas consolas, mientras que en Europa fue lanzado solamente para la PlayStation el 13 de octubre de 1997.[cita requerida] La versión para PC fue publicada el 3 de diciembre de 1998 en Japón y en 1999 en Norteamérica y Europa, y se ejecuta en varios sistemas operativos, entre ellos Windows 95 y sus versiones posteriores.

2 versions of Mega Man X4

You're viewing: Mega Man X4

Mega Man X4github.com/sozud/mmx4
Windows
Current
MegaManX4Recompgithub.com/mstan/MegaManX4Recomp
Windows
Linux
macOS
›

Official project information

Author's original READMEOpen on GitHub ↗

Mega Man X4

A matching decompilation of Mega Man X4 (PlayStation, 1997).

US JP EU Build

The same C source builds:

  • byte-matching PlayStation executables for the US, JP and EU releases
  • a native PC port for Linux (US and JP)
  • a non-matching Sega Saturn build

This repository does not contain any game assets. You need your own copy of the game.

Versions

VersionExecutableCompilerChecksums
USSLUS_005.61GCC 2.7.2check.us.txt
JPSLPS_009.02GCC 2.7.2check.jp.txt
EUSLES_011.76GCC 2.8.1check.eu.txt
Saturn US0.BIN, X4LOW.X4sh-elf-gcc (retail: SHC)non-matching

Building the PlayStation executables

Install the dependencies:

sudo apt-get update
sudo apt-get install binutils-mipsel-linux-gnu gcc-mipsel-linux-gnu ninja-build

pip install -r requirements.txt

git submodule update --init --recursive
sh compiler.sh

Copy the executable from your disc into disks/<version>/, for example disks/us/SLUS_005.61. Then split and build:

splat split config/SLUS_005.61.splat.yaml
sh build.sh

For the other versions, split with config/SLPS_009.02.splat.yaml or config/SLES_011.76.splat.yaml and run VERSION=jp sh build.sh or VERSION=eu sh build.sh. build.sh checks the result against check.<version>.txt.

Building the PC port

sudo apt-get install build-essential cmake ninja-build \
    libx11-dev libxext-dev libxrandr-dev libxcursor-dev \
    libxfixes-dev libxi-dev libxss-dev libxtst-dev

cmake -S . -B build-linux -G Ninja -DCMAKE_BUILD_TYPE=Release -DMMX4_PC_VERSION=us
cmake --build build-linux --parallel

Use -DMMX4_PC_VERSION=jp for the Japanese version. The port reads the game data from a disc image, disks/mmx4.us.cue (or disks/mmx4.jp.cue) by default. Pass --cue or set MMX4_CUE to use another path:

build-linux/mmx4_pc --cue path/to/game.cue

Building for Saturn

The Saturn build uses GCC (sh-elf-gcc) instead of Hitachi's SHC compiler. We don't have the exact SHC version the original was built with, so it doesn't match byte for byte.

sudo apt-get install gcc-sh-elf binutils-sh-elf ninja-build
git submodule update --init tools/saturn/sdk
python3 tools/saturn/saturn_native_build.py --output build/saturn-native --jobs $(nproc) --no-disc

Contributing

See the Getting Started page on the wiki.

Project layout

PathContents
src/maindecompiled game code
src/pcPC port platform layer
src/saturnSaturn platform layer
includeshared headers
configsplat configs, symbol lists
testsunit tests
toolsbuild, matching and testing tools
Read official guide
CALIFICACIÓN
—
Loading votes…
Advertisement

PROJECT FILE

Project type
NATIVE PORT
Genre
Platformer
Status
alpha
Original platform
—
Technology
Native C/C++ port (engine reimplementation)
Version
—
Updated
—

Target platforms 1

Windows
View on GitHub
Advertisement