A really long time ago, I posted in history – What features contributed to the evolution of Pascal? – Programmers indicating there was a Hard Disk Image of MS-DOS 6.22 with Pascal for Computer Studies. In fact, that is an IMG file of a DOS hard disk. And this posts shows how to use it with VMware Fusion on Mac OS X. The is a hard disk image contains:
- A full version of MS-DOS 6.22 (MSDN Original)
- Borland Turbo Pascal 7.0 (main)
- Borland Turbo Pascal 6.0
- Borland Turbo Pascal 5.5
- Microsoft QuickPascal 1.0
DOS on a Mac
At the end of last century, nobody would expect to even run a terminal shell on Mac OS. And indeed, up until Mac OS 9, this was impossible. But in 1999 (Darwin) and 2000 (Mac OS X Server 1.0) Apple introduced Terminal.app into OS X (called OS X since 10.8), allowing access to the command line shell. x86 support is another thing though: the early Macintosh was Motorola 68000 based and later Macs were PowerPC based. In 2005 the Apple’s transition to Intel processors became clear. Mid 2006 the first Intel based Mac was introduced based on what commonly is called the Apple-Intel Architecture. They ran Mac OS X 10.4 “Tiger” which supported both Intel and PowerPC. In 2009, PowerPC support was dropped with Mac OS X 10.6 “Snow Leopard”. Without a form of emulation, you could not run one architecture on top of the other. Luckily, these products appeared:
- Mac 68K emulator which was present in all PowerPC versions of Mac OS X could run Motorola 68000 based binaries and Fat binaries. Now you can use SheepShaver to fully emulate a classic Mac.
- Rosetta - based on QuickTransit - supported emulating PowerPC from Mac OS X 10.4.4 until Mac OS X 1.6 that can run Universal binaries.
- SoftPC and SoftWindows emulated a full PC (SoftWindows included a Windows license).
- Connectix had Virtual PC (and the unreleased Virtual Server) for the Mac, which was sold in 2003 to Microsoft which in 2006 announced it would not be supported on Intel-based Macs.
- Bochs supports emulating x86 on many architectures.
But emulation is slow (in the early 1990s you even had Apple’s DOS Compatibility Cards that were basically a PC in a NuBus slot, before that in the late 1980s AST had similar x86 cards), so I never used these architectures, and now that all Macs have been Intel based, you can use another technology that is much faster: Hardware-assisted virtualization.
Eric Traut is a name to watch with respect to emulation and virtualization. He worked at the Mac 68K emulator, Virtual PC, Virtual Server and Hyper-V. Now he is a Microsoft Distinguished Engineer in the Virtualization area.
Virtualization
I choose VMware Fusion for running this hard drive image, as virtually (pun intended) all my development and production environments run under a VMware product, and exchanging machines between them is a breeze. In the future, I might try one of these to see if the steps are any easier based on the Comparison of platform virtual machines page on WikiPedia:
- Emulation products
- QEMU: it emulates so many platforms that I’m very curious to get this to work on a Mac.
- DOSBox; see this video: Running DOS Programs on Mac With DOSBox (Macintosh OS X) – YouTube. Note: Free DOS games for Boxer is based on DOSBox.
- Virtualization products
The HDD image on VMware Fusion
The Hard Disk Image of MS-DOS 6.22 with Pascal for Computer Studies uses the IMG file extension. Like many DOS and Windows disk images it is a physical disk dump, but unlike IMA/FLP floppy disk images, hard disk images can take up a lot of space when the imaged disk is large, even when little of that space is actually in use. Thats why virtual disk images (like VHD, VMDK, VDI or HDS) often use sparse formats where unused portions are not stored. The IMG extension is unfortunate, as it is also used for other formats, for instance CD/DVD ISO images, RLE bitmap images and others. Luckily, this IMG file is compatible with a VHD file. Though VMware Workstation and VMware Player have built-in support for VHD, VMware fusion is not, so I needed a way to convert the VHD into VMDK. There are a couple of ways to do this:
- .NET/C#/PowerShell: building .NET DiscUtils library for virtual disk images.
- using WinImage as it understands both IMG, VMDK and VHD: VMware: Convert VHD to VMDK with WinImage | VMpros.
When you have converted the CSBOOT.IMG into VMDK, then you can import it in VMware Fusion.
The disk image also includes the most basic IDE CD-ROM driver shipped with the MS-DOS 6.22 boot diskette and the Microsoft Mouse Driver 8.20 which is commonly used (only with PS/2 mouse, like what we have at school).
After booting up, you can type:
- cls: Clear screen
- turbo/tpx: Launch Turbo Pascal 7.0
- turbo60: Launch Turbo Pascal 6.0
- turbo55: Launch Turbo Pascal 5.5
- qp: Launch QuickPascal Download
Download
http://michael960308.webs.com//downloads/csboot.zip
Screenshots
–jeroen
Filed under: Borland Pascal, Development, Fusion, Pascal, Power User, Quick Pascal, Software Development, Turbo Pascal, VMware, VMware Workstation