The PC version of the Nintendo Switch version of a great PC game from 2003!
About rRootage
rRootage is a bullet hell game by Kenta Cho (aka ABA Games), released in 2003 as free software with the 2-clause BSD license.
I was recently thinking about games I like that weren’t on Steam and that led me to think about rRootage again. It’s an old favourite of mine, which I first discovered long ago while browsing the games section of the Ubuntu repos, back when it still used Ubuntu Software Center as the frontend. From there, I discovered that someone actually released a Nintendo Switch port of the game in 2021!
Victor Blanco’s rRootage Reloaded is a source port of the original but with a modernized code base and some minor enhancements. He wrote a blog post about the porting process. What interested me is that he also released the source code for his port. The original rRootage’s source code was a straightforward mix of C and C++ that used SDL, and rRootage Reloaded was the same, though SDL had been upgraded from 1.2 to 2. Because there weren’t any opaque sorceries in the source code, I suspected it would be possible to build rRootage Reloaded for any target the original could build for.
What I’m doing here
It took me about a month of work on-and-off, but I eventually confirmed my hypothesis. I built rRootage Reloaded and ran it on Linux. This is a PC port of a Switch port of a PC game. Effectively, it’s a fork of the game with a modernized code base and some small feature updates.
Getting rRootage Reloaded to build
In Victor Blanco’s git repo for rRootage Reloaded, there are a few commits in the git log that hint at the possibility of building for Linux, but it wouldn’t build out-of-the-box. The documentation is thin and some files, like the CMakeLists, show signs that the build process was hardcoded to fit his personal setup, so I had to suss out how to create a more portable build process.
One part of this was figuring out what the exact dependencies were. This is one annoyance I have with C and C++: the lack of any (relevant) package managers means having to depend on documentation to find out what libraries to install. There wasn’t much documentation in this repo, but my biggest hint was the GitHub Actions file, which lists a CI job that has an Ubuntu VM install various packages before building the project. What was a bit suspicious was that the job was installing packages like libsdl1.2debian
, but rRootage Reloaded used SDL 2, not 1.2, so I had to assume that these dependencies were outdated.
But this was at least a start. I could start by trying to match what the CI job was doing, so I used Toolbx to create an Ubuntu container to try this in. With this container, I managed to figure out the right dependencies for the project and track down the rest of the build errors. The CMake build files were misconfigured and were failing to find the SDL headers. One header file was missing. Some minor code errors were holding up compilation.
Once all I sorted all that out, I managed to complete the build process without errors and finally have a runnable game. To confirm that my fixes worked, I tried to replicate the build with a fresh Toolbx container, this time running Fedora. With some experimentation, I narrowed down the exact set of dependencies the game needed to build; some of the packages turned out not to be used in the build process at all.
Results
With this minor, month-long adventure, I established that it was indeed possible to play Victor Blanco’s rRootage Reloaded fork on PC. I’ve recorded my progress in my own fork of rRootage Reloaded. Wow, a fork of a fork!
Now that it builds, I’ll now have to take the time to clean up my personal notes and the mess I made in the source tree. I want to better document the process of building rRootage Reloaded and try to more diligently track licensing info — by this point, several people have touched rRootage’s BSD-licensed code.
I give my gratitude to Victor Blanco for doing the work to modernize rRootage, port it to Switch, and also release his changes so I could benefit from them as well.
Potential future steps
So far, all I’ve done is build the darn thing. But now that it does build, I have an opportunity to build on top of this base. I have a bunch of speculative ideas for this:
- rRootage’s 22nd anniversary is coming up. I could make something special to celebrate.
- The Debian package for rRootage is built with some patches that improve the game slightly, like a resolution that isn’t hardcoded. I could port in Debian’s changes.
- I could port rRootage to run in web browsers using Emscripten. Emscripten already has SDL support and the rRootage Reloaded source code isn’t hyper-specific to any platform, so this looks doable.
- In the time it took me to figure out building rRootage Reloaded, SDL 3 released. I could upgrade the version of SDL used in rRootage.
- There are a bunch of longstanding bugs and quirks in the game that I could fix. (I only know of these bugs from having played the game so much.)
- I could add some minor enhancements to make the game nicer to play, but without changing the identity of the game.