In our last issue we talked about emulating Linux on your Windows PC using Qemu (Multi-OS Emulation, page 50). This time, we will emulate a Mac on Windows. For this we will use Pear PC, an open-source emulator that can run Mac OSX. It works on image files, to emulate the hard drive and CD/DVD ROM drives. You need a licensed copy of a Mac OSX DVD and convert it to an ISO image file.
First you need to create a Mac OSX installation DVD ISO image. For that, put the Mac OSX installation DVD into the drive and launch Nero CD burning software. Here select Extras>Save Tracks. You will get Save Tracks window. Here go to 'Output File Format' select 'ISO Image File (*.iso)'. set its path to where you would want to save the image. Click on Go to create a DVD ISO image. We named it as 'Mac1.ISO'. After this, you need to create a raw image of a hard drive for use in your emulator.
|
Create a Mac disk image
To create a pre-formatted (HPFS) Mac disk image we will use the MAKEIMG utility, given on this month's PCQXtreme CD. Copy makedsk.zip from the CD to your desktop and unzip it. You will get two files MAKEDSK.EXE and MAKEIMG.EXE. Double click on MAKEIMG.EXE and it will open the utility in a command window. Enter the complete path for the blank image file (c:\pearpc\mac.img). Then enter the size of the image file that you want to create (enter 2064384). It will take a few minutes to create a blank image file. This utility can create an image only up to 2 GB. The Mac emulator requires IMG files sized in multiples of 516096 (roughly 500 MB) bytes. So to create an image of 2 GB, it would require 4 x 516096 bytes=2064384 MB=1.96 GB (approx 2 GB).
Configure Pear PC
Copy pearpc-0.3.1-win32-sdl-jitc.zip from this month's PCQXtreme CD to your desktop and unzip it in a separate folder. To create a config file in the same folder, open the notepad and write the entries as shown in the box on the next page. Save this file as Macconf.cfg and make sure that the .img and .iso images file that you are using in the config file, are written correctly.
Run the Pear PC emulator
Open a command window and go to the folder where you unzipped the Pear PC and issue:
C:\ppc>ppc.exe Macconfig.cfg
|
This will open a Pear PC emulator interface and boot the emulator from the DVD ISO. After a few minutes, you will get an installation screen of Mac OSX. Select Installer>Open Disk Utility. From the left window panel of Disk Utility window, select the 2.0 GB disk and on the corresponding right window panel you will get its settings. Select the Erase tab and give a name to this disk. Then click on the Erase button. This will format the disk according to Mac OSX. After this close the Disk Utility window and return to the installer.
Select the language preferences and click on Continue. After agreeing to the license agreement, you will be shown a disk that has been formatted for the Mac, in the 'Select Destination' window. Select the disk and click on Continue. Now, select the packages that you want to install.
By default, Mac OSX needs more then 2 GB for a complete install. But unfortunately, we could make only 1.96 GB of blank disk image from the 'MAKEIMG' utility. So to fit in Mac OSX in 1.96 GB, you need to omit few packages. You can skip Fonts, Speech Software, Printer Drivers, iMovies and iPhoto packages. Select the packages that you want and click on Install.
Installation will take a few hours for Mac OSX. After that it will reboot your emulated Mac. Now, open the config file ('Macconfig.cfg') again in the notepad and change the entry shown below.
|
prom_bootmethod = "select"
Save this file and run the emulator again as before. You will get the boot selection menu (hard disk or CD-ROM). In this selection screen, select the hard disk option, and the Pear PC emulator will automatically boot from emulated MAC hard drive. And in few minutes, you will see MAC OSX running on your Windows Machine.
Sanjay Majumder