Building a Retro Linux Gaming Computer
Part 27: Lost Souls

By Hamish Paul Wilson
First published on 2023-02-27

Continued from Part 26: Coming to You Live

Return to Index

I have mentioned before how I was unable to get Dave Taylor's original port of Doom to work as it was built as an outdated a.out binary rather than ELF. Since then, I stumbled on an article by Jason Heiss that describes how to load the binfmt_aout kernel module to attain a.out binary support, as well as installing the ld.so-1.9.5-13.i386.rpm and aout-libs-1.4-9.i386.rpm packages from earlier Red Hat Linux releases to provide the necessary libraries.

Sure enough, with those in place the primordial Linux port of Doom works, albeit from an XFree86 server configured to run at only 8 bit colour depth. The other expected limitations apply such as the lack of any music, but the strangest issue I had was with the sound effects. On first launch I was hearing Heretic noises, as Doom was using the sndserver binary from the Linux Heretic source port installed in /usr/local/bin rather than its own. Replacing the sndserver solved the issue.

Another spanner in the works is that the X11 version of Doom is in effect keyboard only. A launch parameter does exist to grab the mouse, but this is bugged; I did get my Perixx PERIMICE-209 WP working with SVGAlib by modifying the ~/.doomrc file to have mousdev set to "/dev/psaux" and mousetype set to "PS2". Under X11 the game runs in a 320x200 window with no full screen option, but you can double or triple the pixels using the "-2" and "-3" parameters.

The shareware release of Doom is included inside the linux-doom-1.8.tar.gz archive I used to install the xdoom and sdoom binaries. Explicit support is offered for the registered Doom and Doom II, with Final Doom possible as a set of add-on WADs. Demo playback only works with the shareware, producing version errors everywhere else. A mixed bag to be sure, but even before the Doom source code was opened, hackers were making improvements to the Linux version.

A fan patch included in the udoom-1.1.tar.gz archive adds support for The Ultimate Doom and seems to fix the demos, while musserver.tgz even hacks in MIDI music through a separate musserver binary. I had to fake the /dev/sndstat device file, but it works. These changes would be mainlined after Bernd Kreimeier tidied up the Linux code for public release, but thanks to Dave Taylor's other studio Crack dot Com, I have another example of a.out insanity I can try as well.

Several iterations of the Linux binaries for Abuse are available, but I opted to install the abuse-1.10-5.i386.rpm package as distributed by Red Hat. This provides a few niceties such as custom launch scripts installed into the /usr/games directory, as well as the original Abuse shareware data with the alien ants storyline. The X11 version launches in a 320x200 window also at 8 bit colour depth, but you can stop the cursor leaving the window with the "-grab_pointer" launch parameter.

This is how Abuse was intended to be played, but you can toggle higher resolutions by using the "-size" parameter. This will disable the lighting engine, as well as exposing more of the level to the point of being considered a cheat by the developers. Due to this they also included a pixel doubling mode using the "-2" parameter that preserves the original viewing area and lighting at resolutions of 640x400 or above. I ran with 640x480 so I could hack full screen like I did with Quake.

A few effects will still only flash in the 320x200 area, and I did have some redrawing issues when loading saved games, but these always resolved themselves on the second attempt. The other problem I had was with the sound effects, which only worked when abuse.x11 was launched with root privileges. Speaking of needing root, abuse.svga which uses SVGAlib starts fine but then stalls at the cursor; I even tried using an old Mouse Systems serial mouse with it but no dice.

If this sounds insecure, it is because it is. In fact, known privilege escalation exploits exist due to how the SVGAlib version of Abuse executes its undrv and sndrv binaries. In some ways we should be grateful for such sloppiness, as it is how we got the SVGAlib version of Quake. Dave Taylor only ported the game to X11, but thanks to the Quake source code being stolen from the Crack dot Com server, coder Greg Alexander was able to finish a port to SVGAlib in just twenty four hours.

Alexander even had the chutzpah to submit the patches to John Carmack, who graciously accepted them without the threat of legal action. Crack dot Com would show the same community spirit by opening up the Abuse source code and releasing most of the Abuse shareware assets into the public domain. This allowed for the creation of enhanced source ports to Linux such as Abuse-SDL, as well as the fRaBs level set using the shareware assets. If only all games could be as lucky.

Carrying on in Part 28: Losing My Marbles

Avatar

Hamish Paul Wilson is a free software developer, game critic, amateur writer, cattle rancher, shepherd, and beekeeper living in rural Alberta, Canada. He is an advocate of both DRM free native Linux gaming and the free software movement alongside his other causes, and further information can be found at his icculus.org homepage where he lists everything he is currently involved in.

http://www.icculus.org/~hamish

Comments

You can use your Fediverse (including Mastodon, among many others) account to reply to this post. You can also follow my Mastodon to be notified when new parts of this series are released.

Further reading and resources:

The article on a.out support by Jason Heiss can be read here:

https://aput.net/~jheiss/aout_redhat.shtml

The Linux Doom FAQ by Steve VanDevender is archived here:

https://hexadecimal.uoregon.edu/~stevev/Linux-DOOM-FAQ.html

The Linux Game Tome entry for Doom is archived here:

http://www.happypenguin.org/show?Doom&showall=1#comments

A review of Doom by Michael K. Johnson for Linux Journal can be found here:

https://www.linuxjournal.com/article/1

The files for the original Linux Doom port are mirrored here:

https://www.ibiblio.org/pub/Linux/games/doom/!INDEX.html

My fake /dev/sndstat device can be seen here:

https://icculus.org/~hamish/dianoga/sndstat

The RPM package for Abuse can be downloaded from here:

https://archive.download.redhat.com/pub/contrib/libc6/i386/abuse-1.10-5.i386.rpm

An RPM package for the upstream patched Linux Doom binaries can be downloaded here:

https://archive.download.redhat.com/pub/contrib/libc6/i386/doom-1.10-7.i386.rpm

A press release on Red Hat partnering with Crack dot Com be be read here:

https://www.redhat.com/ja/about/press-releases/press-crackdotcom

A detailed overview of Abuse versions can be seen in this VOGONS thread:

https://www.vogons.org/viewtopic.php?t=44100

The Linux Game Tome entry for Abuse is archived here:

http://happypenguin.org/show?Abuse&showall=1#comments

Security reports on the exploits found with the SVGAlib version of Abuse can be read here:

https://www.exploit-db.com/exploits/19279
https://vulners.com/packetstorm/PACKETSTORM:15084

An article on the Quake source code leak from Wired can be read here:

https://www.wired.com/1997/01/hackers-hack-crack-steal-quake

An interview with Dave Taylor on Linux gaming by Harley Jebens for Gamespot can be read here:

https://www.gamespot.com/articles/okay-dave-taylor-why-linux/1100-2467851

An interview with Dave Taylor on Linux gaming by James Hills for GA-Source is mirrored here:

https://www.talisman.org/~erlkonig/misc/ddt.shtml

And my launch command for Abuse is as follows:

sudo /usr/games/abuse.x11 -2 -size 640 480 -grab_pointer




Addendum:

I would like to clarify that launching Final Doom as a Doom II add-on will likely result in some issues cropping up due to changes made to the Final Doom binaries that the WAD files shipped with.

For Final Doom a source port such as LxDoom as mentioned in Part 16 would be more appropriate. Part 38 also contains more details on the original Linux Doom port.


Licensed under Creative Commons Attribution-ShareAlike 4.0 International (CC BY-SA 4.0)