Claudio Fontana

/hobbies

Random. Do not expect(1) this stuff to remain here.


Extract UHARC under Unix

I have struggled to find a way to extract .UHA (UHARC) files under GNU/Linux, and finally I found a way. I report it here in case someone needs it:

First of all, ensure that you have the dosbox emulator as source code.

Then, get the DOS version of the UHARC command line utility. You can find it in the WINUHA site.

At this point, download this patch for dosbox. It is a very stupid patch, that you should only use for this purpose. Apply it from the top source directory of dosbox using patch -p0 < PATCH_FILENAME.

Install this special version of dosbox (call it dosbox-uharc or whatever), and then you will be able to extract files from the UHARC archive. The patch is necessary to be able to write long filenames.

The basic extract syntax for the UHARCD.EXE utility is:

uharcd x ARCHIVE_NAME

Run uharcd without any arguments to get the full list of supported options.


Running the Spirit Engine under wine

The Spirit Engine is an interesting freeware game that more or less runs under wine.

However, with plain wine the preferences and more importantly saved games do not get saved or loaded correctly. This makes the game effectively unplayable.

To work around this problem, first download wine source code.

Then download wine-profile-fix2.p0.diff, a patch which solves most critical problems.

Unpack the wine source code, for example issuing:

$ tar -jxvf wine-VERSION.tar.bz2

Enter the wine source code directory that has been created:

$ cd wine-VERSION

Apply the patch to wine source:

$ patch -p0 < PATH_TO/wine-profile-fix2.p0.diff

Build wine normally, using ./configure && make && make install or using a source installer.

Enjoy!