The blog

Building dosemu2 to run WordPerfect for DOS on debian

We are going to run wordperfect for dos on dosemu on debian. Overcomplicated adventure building stuff as debs for no reason.

Main source of inspiration is and the linux page there. Apparently there is a new way with dosbox-x which is better, but I don’t seriously intend to use WP, I’m just toying, so I won’t ask.

I wrote down what I did as I went, but reordered sections to be in logical order instead of chronological.

Let’s go with dosemu2. I’m running bedrock linux on this laptop, with debian and void. But dosemu2 is not in either’s repo. We could try to use the ubuntu debs, but it feels wrong and there is no fun in that. So time to build from source.

We’ll need some normal dependencies we can get from apt, but we will also need fdpp.

git clone

The readme claims make is all you need - it’s never that easy

sudo apt install libelf-dev bison flex clang texinfo asciidoc-base xmlto

(note this pulls a ton of tex shit, maybe there’s a way to make it more minimal)

As of writing, fdpp depends on a custom nasm which is hosted on launchpad.

git clone
git checkout elf16
debuild -i -us -uc -b

We could add --lintian-opts --suppress-tags bad-distribution-in-changes-file telling lintian to ignore that because we are building an ubuntu package, but it turns out that lintian doesn’t matter, it gives some errors but the build is fine.

sudo apt install ../nasm-segelf_2.16.01-2_amd64.deb

Back on fdpp:

make deb
sudo apt install ../fdpp_1.7-1_amd64.deb ../fdpp-dev_1.7-1_amd64.deb

Now it turns out that dosemu2 will also want comcom32, so let’s do that:

git clone

New subquest, we need the djgpp toolchain. We are going to need normal nasm this time.

sudo apt install dos2unix nasm

This one will take forever

git clone
debuild -i -us -uc -b
sudo apt install ../binutils-djgpp_2.41+11_amd64.deb \
../djgpp-dev_2.05.cvs.20230827.1621+11_amd64.deb \
../djgpp-utils_2.05.cvs.20230827.1621+11_amd64.deb \
../gcc-djgpp_12.2.0+11_amd64.deb ../gdb-djgpp_8.2.1+11_amd64.deb \

Back on comcom32:

debuild -i -us -uc -b
sudo apt install ../comcom32_0.1\~alpha3-1_all.deb


git clone
sudo apt install linuxdoc-tools libslang2-dev libgpm-dev \
libsdl2-ttf-dev libfontconfig1-dev ladspa-sdk libfluidsynth-dev \
libao-dev libieee1284-3-dev libslirp-dev libbsd-dev \
libreadline-dev libjson-c-dev libb64-dev binutils-dev binutils-i686-linux-gnu
make deb
sudo apt install ../dosemu2_2.0~pre9-1_amd64.deb

I’m not going to bother with uninstalling all the stuff we installed just for building honestly.

Once I got dosemu2 booting, I fetched a copy of WordPerfect 6.2, extracted the contents of the images:

sudo mkdir -p /mnt/a
mkdir -p out
for i in *.img; do
    echo "$i"
    sudo mount -o loop "$i" /mnt/a
    cp -rv /mnt/a/* out
    sudo umount /mnt/a

Then went through the install, selecting the Apple LaserWriter IINTX for the printer, forgetting to select the VESA driver (so I did that part to get high resolution later), and basically following the WPDOS guide as well as I could. I also replaced the binary for the patched version in the archive, which gives me shift+arrow keys selection. The mouse is a bit weird and too fast in my dosemu2, so I have an emumouse line in my USERHOOK.BAT file.

emumouse x 2 y 4

A screenshot of the result:
Screenshot from WP6 running on dosemu2 on debian

Printing just works, dosemu2 passes down the file to the CUPS default printer. CUPS-PDF can be used to print to PDF.


Got any comments? Send me an email: