Sunteți pe pagina 1din 17

The

all-in-one guide to vanilla OS X Mountain Lion + Chameleon + DSDT for beginners Preface: So Ive built a few hackintoshes now to the point where Ive a good idea what Im doing. Ive gone the distro way before as well as the vanilla way and I agree fully with the idea that vanilla is better. The problem with it being that I havent found a well explained start to finish guide of how to do it without a lot of googling and combining numerous different guides so my idea is to collate everything into one place for beginners to hopefully understand the process better and build better systems. A lot of the leg-work for this guide has been done by other people; although Im rewriting most of it if anyone wants credit adding to something Ive accidentally stolen from them just PM me. Throughout the guide I try to avoid scripts and utilities so you can learn what your doing. If you want a one-click install this is not the guide for you; having said that there is nothing technically complicated that isnt clearly explained so dont be scared off if youre a rookie. If any one has any suggestions on how to improve this guide PM me or mention it on the forum thread. Those who experience problems make sure youve read Part 7 before posting to the forum asking for help. For anyone who has done this before please note that in Mountain Lion legacy 32-bit boot (arch=i386) and /Extra/Extensions are now depreciated.

Contents Page Preface 0 Contents 1 1. Prerequisites 2 1.0 Basic requirements 2 1.1 Essential software 2 1.2 Essential kexts 2 2. Creating the installer 3 2.0 Preparing the USB 3 2.1 Creating the OS X installer on the USB drive 4 2.2 Patching the installer for a PC 6 2.3 A note for those wishing to boot OS X and Windows 8 on the same HDD 8 2.4 Hide hidden files 8 3. Installing OS X 9 3.0 Installing OS X 9 3.1 Fixing the install 9 4. Initial boot 9 5. DSDT 10 5.1 Extraction 10 6. Finishing touches 11 6.0 A note on non-Mac monitors 11 6.1 Keymaps 11 6.2 org.chameleon.boot.plist 11 6.3 NullCPUPowerManagement 12 6.4 Device compatibility 12 6.5 Finder grid view 12 7. Common errors & basic diagnostics 13 7.0 Boot0:error 13 7.1 Boot flags 13 7.2 The console 13 7.3 App store Your computer could not be recognised error 13 7.4 Motherboard POST freeze 14 7.5 When posting to the forum for further help 14 7.6 ATi6xxx card white screen error 14 8. Useful tips 15 8.0 To show or hide hidden files 15 8.1 Spaces in terminal 15 9. References 16 10. Change-log 11

Part 1 - Prerequisites 1.0. Basic Requirements: The basic requirements for Mountain Lion are: 1. A Core 2 Duo processor or later 2. 2GB or more RAM 3. 8GB of disk space N.B. For details of specific hardware compatibility see the hardware compatibility list (HCL) in the wiki: http://wiki.osx86pro.../HCL_10.8_Seeds Further to compatible hardware you will need: 1. A working install of OS X (this may be in a virtual machine or a native install) to prepare the installer 2. A flash drive of minimum size 8GB 3. A copy of Mountain Lion 4. Patience Note: All essential software / kexts below are in the OP attachment. 1.1. Essential Software You will need to obtain the following. I suggest you place them all in the same folder along with the essential kexts below for use later: 1. The Chameleon boot loader, the latest version of which can always be found here (You want "The Latest Trunk PKG ~ Standard and Official Revision"): http://www.insanelymac.com/forum/index.php?showtopic=231075 2. Chameleon wizard to create a smbios (basically identify your machine as a mac) and to help with bootloader problems http://www.insanelymac.com/forum/index.php?showtopic=257464 3. System info for finding device IDs for general post-install troubleshooting (Check you get the Mac version). http://www.insanelymac.com/forum/index.php?showtopic=219584 4. DSDT editor for extracting your DSDT once were up and running: http://www.insanelymac.com/forum/index.php?showtopic=223205 5. Kext utility for installing additional kexts post-install: http://cvad-mac.narod2.ru/Kext_Utility/ 1.2. Essential Kexts (kernel extensions) 1. FakeSMC absolutely essential tricks OS X into thinking its a real Mac. http://www.projectosx.com/forum/index.php?showtopic=1643 2. NullCPUPowerManagement generally required initially to prevent kernel panics, may not be needed once AppleIntelCPUPowerManagement is patched after install. http://www.osx86.net/view/16-nullcpupowermanagement_(32--64-bit).html

Part 2 - Creating the installer 2.0. Preparing the USB 1. In your working OS X install open Disk Utility 2. Click on your USB drive in the left sidebar 3. Click the Partition tab 4. Under Partition Layout click 1 Partition 5. Click Options -> select GUID Partition Table; check the format is set to Mac OS X Extended (Journaled); name it USB and click Apply

Fig 2.0: Preparing the USB.

2.1. Creating the OS X installer on the USB drive 1. Show hidden files in finder by opening Terminal (in utilities) and typing (copy / pasting) the following: defaults write com.apple.finder AppleShowAllFiles YES then killall Finder 2. Mount your Mountain Lion DMG. If using a copy downloaded from the app store: Navigate to Applications (which is where it will save your downloaded copy of ML by default) -> right click "Install OS X Mountain Lion" and click "Show Package Contents" -> Contents -> SharedSupport -> Double click "InstallESD.dmg" 3. Mount BaseSystem.dmg by typing the following in terminal: open /Volumes/Mac\ OS\ X\ Install\ ESD/BaseSystem.dmg 4. Go back to disk utility and click on Mac OS X Base System, click the Restore tab then drag and drop your USB to destination and click restore then erase. This will take a while. 5. Youll now have 2 Mac OS X Base Systems present in Finder, right click them and get info to determine which is your USB drive (hint: look at the size). 6. Navigate to the one which is your USB drive, open it and go to /System/Installation. Delete the Packages link then create a folder called Packages. 7. Open a new Finder window and navigate to Mac OS X Install ESD. Copy everything inside the packages folder to the packages folder you have just created. This will take a while. 8. Copy mach_kernel from Mac OS X Install ESD to the root of your USB drive.

Fig 2.1.1: Restoring Mac OS X Base System to the USB drive.

The terminal will look like this when you are done:

Fig 2.1.2: Terminal output.

2.2. Patching the installer for a PC 1. Remember the two kexts we downloaded above? Copy both of them to /System/Library/Extensions on your USB stick. 2. Run the chameleon installation package and ensure to choose your USB drive as the destination. 3. Go to the root of your USB drive and create a folder called Extra. This is used to store configuration files for the chameleon boot-loader. 4. Open Chameleon wizard, click the SMBios tab then click "Edit". Now there is a list of Premade SMBioses. Look through this list to see which relates best to your PC (Hint: iMac 12.2 for modern desktops or MacBook Pro 8.3 for modern laptops is a good place to look to start with). Click Save As and save it to the /Extra folder we created on the USB stick. N.B. make sure youve got a smbios from a Mac which supports Mountain Lion, for a list of which do see here: http://www.apple.com/osx/specs/ 5. Copy your folder of essential software & kexts to the root of your USB stick. N.B.1: for those with a fully-working Lion install you may omit 2.C.3. & 2.C.4. and use your old /Extra folder (including smbios & org.chameleon.boot.plist & DSDT).N.B.2: ATi6xxx users see step 7.6 now!

Fig 2.2.0: Change install location in chameleon installer.

Fig 2.2.1: Select USB partition in chameleon installer.

Fig 2.2.2: Creating SMBios.

Fig 2.234: Creating the SMBios ctd.

2.3. A note for those wishing to boot OS X and Windows on the same HDD (This is not recommended but may be necessary for those installing on laptops) The OS X installer wont install to an MBR partition scheme which Windows requires so we must patch the installer to allow this. If you intend on dual-booting OS X and Windows then I suggest you install Windows and update to Service Pack 1 before you install OS X to prevent problems updating to SP1 later. How to patch: 1. Download the required files from here: http://www.osx86.net/view/2815-osinstallmbr+osinstall.mpkg_10.8.gm.html 2. On the USB stick navigate to /System/Installation/Packages/. Delete OSInstall.mpkg and replace it with the one you just downloaded. 3. On the USB stick navigate to /System/Library/PrivateFrameworks/Install.framework/Frameworks/OSInstall.frame work/Versions/A/. Delete OSInstall and replace it with the one you just downloaded. 2.4 Hide hidden Files 1. Hide hidden files in finder by opening Terminal and typing: defaults write com.apple.finder AppleShowAllFiles NO then killall Finder

Part 3 Installing OS X 3.1 Installing OS X 1. Stick the USB drive in the computer you wish to install ML on and boot from your USB drive. If youre unsure how to do this when your computer first turns on look for a prompt that says Press X for boot selection menu (where X is a key) or something of that effect. Common keys are F8 & F12. 2. When Chameleon comes up press enter to boot OS X. The OS X installer should boot. Go to the utilities menu and click disk utility. Select the disk / partition you wish to install OS X to, call it "OS X" and format it as Mac OS X Extended (Journaled) (See Part 2.1. if youre a bit rusty with disk utility). N.B. For those dual booting on the same HDD as Windows ensure you've got the Partition Scheme as MBR. 3. Follow the installer to install OS X to the desired partition. 4. Take a well-deserved rest while it installs. 5. Once the installer is finished it will reboot, on reboot boot back into the install USB NOT your OS X install. 3.1 Fixing the OS X install 1. From the installer go to Utilities and Terminal. 2. Type cp R /System/Library/Extensions/NullCPUPowerManagement.kext /Volumes/"OS X"/System/Library/Extensions/ 3. Type: cp R /System/Library/Extensions/FakeSMC.kext /Volumes/"OS X"/System/Library/Extensions/ 4. Type reboot NOTE: Include the quotes in the lines above. This assumes your install partition is called OS X as I said above. If for whatever reason you called it something else replace OS X with whatever you called it. Part 4 Initial booot 1. Reboot your system and boot to the USB stick again but this time select your OS X install. This should boot you into your installed copy of ML. 2. Open "System Preferences" go-to "Security and Privacy", click the lock and give it your password then set "Allow applications downloaded from" to anywhere. 3. Navigate to your folder of essential software and run the chameleon package, install it to your OS X drive. 4. Copy the Extra folder on your USB drive to the root of your HDD (open Finder -> Go -> Computer -> OS X -> paste folder). 5. Reboot and let the computer boot from your HDD, select OS X and it should boot straight to ML. You are not finished! You now need to at least read through step 6!

Part 5 DSDT 5.0 Extraction Although not strictly required it is useful to have a DSDT for your system; with a bit of research and patching it can be used to solve almost all problems you may encounter. For those interested in what it actually is see here: http://wiki.osx86pro.../index.php/DSDT How to create it: 1. Open DSDT Editor 2. Go-to File -> Extract DSDT 3. Go-to to IASL -> Compile (if you get any errors click Fix Errors) 4. Go-to IASL -> Save AML as. Save it as DSDT.aml in /Extra. 5.1 Common Fixes (coming soon)

10

Part 6 Finishing Touches 6.0. A note on non-Mac monitors Most non-Mac monitors will start with the wrong color calibration. To fix this go-to "System Preferences" -> "Displays" -> "Color" -> select "Generic RGB Profile" 6.1. Keymaps Apple and windows have different key-maps so some keys on the keyboard will be wrong. This can be corrected by using the correct key-map. Included in the forum attachment is both the key map for a mac keyboard on windows and a (generic) windows keyboard on mac. 6.2. org.chameleon.boot.plist If you open Chameleon Wizard you can navigate to org.chameleon.boot here you can assign numerous settings which will be useful later as well as setting the default timeout and specifying the location of your SMBios and DSDT if you dont place them in /Extra. I suggest you ensure the Ethernet Built In box is checked then set the "Time Out" to a reasonable figure and then click "Save As' and save it to /Extra (Note: save it as org.chameleon.boot, it automatically appends the .plist extension). When you've saved it you can go to "Theme" and download and apply a theme for the boot loader rather than having the default text boot. Once your system is stable and with all necessary hardware enabled set UseKernelCache=Yes to speed up boot times.

Fig 6.0: Example org.chameleon.boot.plist.

11

6.3. NullCPUPowerManagement Currently we have NullCPUPowerManagement.kext installed. This disables speed- stepping and thus sleep (by disabling AppleIntelCPUPowerManagement.kext) so we need to remove it for a better system. Unfortunately not all systems will work with the version that comes with OS X. The first thing to do is to try your system without it, to do this simply navigate to /System/Library/Extensions on your OS X drive and delete it then reboot. Its possible you will see a kernel panic on reboot, if this is the case you will need to reinstall the kext by following Part 3.1.1&3.1.2. If your system panics on boot then you require a patched version of AppleIntelCPUPowermanagement; reading round the forum should allow you to obtain this relatively easily. 6.4. Device Compatibility At this point its very likely you will have some devices not working. The best way to get devices working is through DSDT edits rather than by adding kernel extensions; often additional kernel extensions will have to be re-installed after updates whereas DSDT edit are permanent. To enable devices by using additional kexts: Run the System Info app we downloaded and click File -> check compatibility. This will let you see which devices are working and which arent. You can Google your vendor & device ID to find info about making them work. Once you find a kext that appears to be compatible for your hardware drag and drop it onto kext utility to install it. Example: If your Wi-Fi isnt working you can look for your Wi-Fi device and find its device / vendor IDs in my case its vendor ID is 168c and its device ID is 002a so Googling for 168c:002a kext would return results about making the device work. 6.5. Finder grid view (windows explorer behaviour) To make finder sort files in a grid by default open Finder, navigate to your root folder of the OS X install. Go-to View -> Show View options -> Arrange by "Name" -> Click "Use As Defaults"

12

Part 7 Common Errors & Basic Diagnostics 7.0. Boot0:Error Boot0 error is most likely caused by incorrectly installing chameleon or having a drive with 4k-sector allocation. Try to reinstall chameleon (use the latest version!), if that doesnt work see here: http://www.macbreaker.com/2012/02/hackintosh-boot0-error.html 7.1. Boot flags When the chameleon screen boots you can specify kernel arguments to attempt to solve problems you may be having. When you see the boot-loader pop up press any key and ensure your OS X install is highlighted. You can then type any combination of kernel flags (with a space between them) to try to boot OS X / diagnose problems. For a complete list of kernel flags see here: http://www.osx86.net/guides-tutorials/10747-guide-chameleon-bootloader- basics.html A few of the more common ones are: 1. v verbose mode. If the system panics take a screen shot of the panic when you have typed this at boot and post it to the forums. It will help eople diagnose your problems but wont fix any problems. 2. x safe boot (like windows safe mode minimal drivers). 3. f boot without the kernel cache (useful if youve installed kexts without rebuilding the kext cache if youve used kext utility you shouldnt have to use this). 4. npci=0x2000 (or npci=0x3000) fixes the PCI configuration Begin error. 5. PCIRootUID=0 solves problems for some NVIDIA graphics card users (if it doesn't solve your issue try =1 instead). 6. GraphicsEnabler=Yes (or GraphicsEnabler=No) add support for some non-OS X graphics cards. 7. Note: The arch=i386 boot flag is now depreciated due to MLs 64-bit only kernel. 7.2. The console The console gives you a verbose output of any and all errors the system may encounter. It's particularly useful if you've a system which won't stay in sleep mode. Go-to Applications -> Utilities -> Console to open it. 7.3. App store "Your device or computer could not be recognised..." error. App-store requires a MAC address to verify your computer (any address, it doesn't have to be an apple one) hence you MUST have a working Ethernet or Airport card for App Store to work. The problem is if you've enabled network hardware after first boot OS X won't update its caches. The fix: Ensure "ethernet buit in" is checked in your org.chameleon.boot.plist. Go to system preferences and delete all the devices in the network section.Navigate to /Library/Preferences/SystemConfiguration and delete com.apple.airport.preferences.plist and networkinterfaces.plist and com.apple.boot.plist. Reboot then add your network interfaces in system preferences. Check app-store is now working.

13

7.4 Motherboard POST Freeze I your motherboard freezes during POST (you dont even get past the BIOS screen) its possible your BIOS isnt compatible with the GUID partition table of the USB we created the installer on. To fix this in step 2.0.5 select MBR instead of GUID. Note: If you make it to the OS X boot-loader this is not your problem and will not fix any issues other than hanging at POST. For more information see here: http://www.rodsbooks.com/gdisk/bios.html 7.5 When posting to the forum asking for help When posting to the forum asking for help if the installer / installation wont boot please post a screenshot of where it stops I suggest you post this to a new thread in a suitable place in the forum rather than this guide. 7.6 ATi6xxx card white screen error There is a know permissions error in Mountain Lion regarding the ATi6000Controller kext causing white screen. To fix this: a. Navigate to /System/Library/Extensions on your install USB and copy ATi6000Ccontroller to your folder of essential kexts. b. Delete ATi6000Controller from /S/L/E. c. Install OS X (note: you will only have basic graphics support). d. After install (at the end of step 4) you can drag & drop the kext onto kextutility then reboot to enable your card.

14

Part 8 - Useful Tips 8.0. To show or hide hidden files: In the terminal type: defaults write com.apple.finder AppleShowAllFiles YES or defaults write com.apple.finder AppleShowAllFiles NO Followed by killall Finder 8.1. Spaces in terminal When using the terminal spaces must be followed by a \ or the file or folder name placed in quotations e.g.: open /Volumes/Mac\ OS\ X\ Install\ ESD/BaseSystem.dmg or open /Volumes/"Mac OS X Install ESD"/BaseSystem.dmg

15

Part 9 References Massive credit goes to this guide here: http://thetecherra.com/2012/07/10/tutorial-run-os-x-mountain-lion-10-8-gm-on-a- pc-hackintoshosx86-video/ and this guide here: http://www.insanelymac.com/forum/index.php?showtopic=277015 Part 10 Change-log v2.3 - 25/07/2012 - Minor update to include InstallESD location from app-store. v2.4 - 27/07/2012 - Minor updates regarding Gringo Vermelhos post. v2.5 - 03/08/2012 - Minor updates and touch-ups. v2.6 - 22/08/2012 - Addition of UseKernelCache=Yes plus key-maps and a few minor tweaks.

16

S-ar putea să vă placă și