The original release of CnC was made legally free for download last year – the ISOs are publicly available all over the internet (for example linked here and here as on the Wine AppDB). And what better way to enjoy this real-time strategy gaming classic than on OpenSolaris using Wine?
Using Wine 1.1.26 as built on a snv_118 x64 system, running on snv_124.
1) mount the ISO as a block accessible device using lofiadm, e.g:
pfexec lofiadm -a /export/home/dkoe001/Documents/Games/CnCGold/CnC_GDI95.iso /dev/lofi/1 pfexec mount -F hsfs /dev/lofi/1 /mnt
2) use winecfg to map a drive to /mnt, configured as a “CD-ROM” drive (using drive D: in my case)
3) I then had to use the following trick to get the CnC installer to actually run – all other attempts were met with the error similar to “Setup cannot find the files necessary to run the installation…”
See post number 3 by “NZLamb”:
So for example:
cd /export/home/dkoe001/.wine/dosdevices ls -l drwxr-xr-x 4 dkoe001 staff 8 2009-10-23 23:20 .. drwxr-xr-x 2 dkoe001 staff 8 2009-10-23 22:50 . lrwxrwxrwx 1 dkoe001 staff 5 2009-10-23 22:34 d: -> /mnt/ lrwxrwxrwx 1 dkoe001 staff 17 2009-10-23 22:33 e:: -> /dev/dsk/c8t0d0s2 lrwxrwxrwx 1 dkoe001 staff 20 2009-10-17 18:09 h: -> /export/home/dkoe001 lrwxrwxrwx 1 dkoe001 staff 1 2009-08-16 16:41 z: -> / lrwxrwxrwx 1 dkoe001 staff 10 2009-08-16 16:41 c: -> ../drive_c ln -s /export/home/dkoe001/Documents/Games/CnCGold/CnC_GDI95.iso d:: ls -l drwxr-xr-x 4 dkoe001 staff 8 2009-10-23 23:20 .. drwxr-xr-x 2 dkoe001 staff 8 2009-10-23 22:50 . lrwxrwxrwx 1 dkoe001 staff 58 2009-10-23 22:50 d:: -> /export/home/dkoe001/Documents/ Games/CnCGold/CnC_GDI95.iso lrwxrwxrwx 1 dkoe001 staff 5 2009-10-23 22:34 d: -> /mnt/ lrwxrwxrwx 1 dkoe001 staff 17 2009-10-23 22:33 e:: -> /dev/dsk/c8t0d0s2 lrwxrwxrwx 1 dkoe001 staff 20 2009-10-17 18:09 h: -> /export/home/dkoe001 lrwxrwxrwx 1 dkoe001 staff 1 2009-08-16 16:41 z: -> / lrwxrwxrwx 1 dkoe001 staff 10 2009-08-16 16:41 c: -> ../drive_c
Installer now runs without issue.
4) Now getting it to run on one core only – running CnC on my Intel Q8200 was unstable to the point of being totally unplayable. Apparently these older games choke on multi-CPU systems.
On snv_124 Wine will run CnC in a full screen nicely, but there is some incompatibility with GNOME such that attempting to bounce out of it (e.g. ALT+TAB) results in the original desktop resolution being nuked in favour of 640×480, if it snaps out of it at all.
So, I execute wine ‘C&C95’ on the CLI, halt the process before it takes over the display, obtain the wine PIDs, and feed these into pbind – for example:
pbind -b 0 1082 1083 1098
where 0 is the CPU number, and 1082, 1083, and 1098 are Wine PIDs. One can use psrinfo to obtain CPU information, and pgrep -l wine to obtain wine PIDs if needed.
Resume the process, and enjoy! Tad kludgy, but a small price to pay for being able to run it on OSOL:
It will run nicely in full screen, as well.
Although Wine runs great on OpenSolaris, there are a couple of annoying bugs in Command and Conquer itself that can really put a dent in the enjoyment of the game – in particular, a bug that causes the game to crash when a field unit moves to the border of the game map where there is as-yet undiscovered terrain. The last official release for Windows was 1.04b, but as one can read on Wikipedia (at least you could before it was edited) there are “unofficial” fan patches which handily resolve this issue – hurrah! Installing these in Wine was as simple as running the .EXEs with the Wine Windows Program Launcher (in the case of the first link for the 1.06 patch):