Jump to content
1 post in this topic

Recommended Posts

So, I'm certain that I'm the only one in the OSx86 and Hackintosh scene who knows about this! I apologize in advanced if this is the wrong place to put it. It's an improvement to existing bootloaders that aid in installing and booting OS X on PC hardware. I don't know though if this is the right place to put it. Anyway, here it goes:

 

Many users here are using Boot-132, PC-EFI, Chameleon, etc. as an EFI bootloader. Not to say that this isn't good, but in order to do what I'm talking about, we need to use a full-fledged UEFI environment capable of booting OS X. So these are a no-go.

 

I didn't even know that there were bootloaders that didn't use modified Boot-132 bootloaders until I was reading about installing Lion DP1 on PCs. Booting it was a challenge on the above bootloaders, and before, it was assumed that you NEEDED UEFI OSx86 bootloaders, like XPC and [url="http://www.insanelymac.com/forum/topic/279450-why-insanelymac-does-not-support-tonymacx86/"]#####[/url] (Not the one by Tonymacx86).

 

I read more about them, and they sounded interesting. However, there was one problem (and still is) in installing it on my Laptop: It used an AMD CPU. As to this day, there is still no news of an AMD kernel for any DPs or the one from the Mac App Store.

 

But, should my plan work, patching kernels will (nearly) be a thing of the past! You see, I read it was possible to use [url="http://www.insanelymac.com/forum/topic/279450-why-insanelymac-does-not-support-tonymacx86/"]#####[/url] and XPC to boot rEFIt on PC hardware, and looked at rEFIt's website at SourceForge. I soon realized that it contained ports of BSD utilities, such as ftp.efi and hexdump.efi, just to name a few. So, I contacted the rEFIt main developer, and this is what I got in reply:

 

Hi Rico,

 

The BSD programs that ship with rEFIt are actually from Intel's "EFI

Applikation Toolkit". That toolkit also contains a port of the BSD C library

that allows compiling BSD commands for the EFI environment. You can

find more information about the current state of the Toolkit at

http://sourceforge.net/apps/mediawiki/tian...le=EFI_Toolkit.

 

-chrisp

I also know that Mac OS X Leopard is capable of booting in QEMU in full system emulation and a slightly-modified Boot-132 disc by David Elliot (just needed additional .kext files so QEMU's IDE hardware will be fully detected, and you won't be stuck at "Still Waiting for Root Device"). You must pass this flag to enable booting via the Vanilla Kernel:

 

qemu-system-x86_64 -cpu core2duo ...

 

And then, before booting, you need to pass on this boot flag in order to bypass a KP:

 

-legacy

 

This will force the kernel to operate in 32-bit mode, and, if done correctly, the installer will load, and you can install OS X on QEMU. However, doing this isn't very practical, only because unlike Windows, QEMU is slower than molasses in January when booting and operating OS X (even when it's the Deadmoo Tiger image, none-the-less retail Leopard).

 

I have done this on my AMD laptop, and even though its slower than PearPC, it still works. But you are probably wondering by now, "How does this translate into booting OS X's Vanilla Kernel on non-supported CPU's?

 

It's actually really simple. Both full system and user mode emulation in QEMU uses the same CPU library. So in Linux or BSD, you could type:

 

qemu-i386 -cpu core2duo some-*nix-command

 

And if you recall up above, BSD commands can be compiled to the UEFI environment. So, therefore, if QEMU user-mode can run on BSD and emulate an Intel Core 2 Duo, and it is ported to the UEFI environment, we could use this to boot OS X. The kernel would see the emulated Intel Core 2 Duo, not the processor the UEFI environment is loaded on. It would therefore boot properly, and you'd be running OS X on non-supported PC hardware.

 

The process goes like this:

 

1. Use some DUET Bootloader to load the EFI Shell

 

2. From there, use a QEMU user mode port to launch either [url="http://www.insanelymac.com/forum/topic/279450-why-insanelymac-does-not-support-tonymacx86/"]#####[/url] or XPC (probably [url="http://www.insanelymac.com/forum/topic/279450-why-insanelymac-does-not-support-tonymacx86/"]#####[/url] since it loads Apple's boot.efi, while XPC still loads the old-fashioned way using com.Apple.boot.plist)

 

3. Load the OS X Installer

 

4. Install like usual and reboot.

 

5. Repeat steps 1-3, but this time, load off of the hard drive.

 

6. Do Step 5 whenever you want to boot OS X.

 

The only issue I'd see with loading the bootloader itself onto the hard drive is when Loading an already-installed version of Windows. This would cause Windows to see a different CPU, and Windows Genuine Advantage would panic, stating your copy of Windows is "not genuine". WGA checks the CPU as it usually wouldn't change, especially from an AMD architecture to Intel's. I'm sure there's a workaround to this, but probably very technical and could be used to a pirate's advantage!

 

However, don't jump for joy yet Lion-on-AMD waiters! The only way this will work is if the kernel is loaded in 32-bit operation mode, an option not likely available in Lion due to Apple dropping 32-bit support in Lion. This is why I'm posting it in the Snow Leopard forum, as using this in Lion would still require some patching due to the kernel to enable 32-bit support to load. You would then also need to copy a 32-bit version of Finder from SL over to Lion since Lion's Finder is purely 64-bit.

 

Anyway, I'd just thought I would share these thoughts with you. No progress has been made yet, since my laptop is low on hard disc space, there is no Live CD (a Live DVD is not an option) available of any open source version of BSD (like FreeBSD and OpenBSD). I only have Windows 7, iDeneb, and Ubuntu on my laptop. I can't even boot into iDeneb since GRUB's MBR overwrote Chameleon's MBR when installing Ubuntu. I would also have to do all Internet activity on either Ubuntu or Windows since OS X isn't compatible with my WiFi adapter. Apparently the manufacturer once had a driver for OS X, but now works with Apple's policy and says to contact Apple when using my WiFi adapter on a Mac.

 

Now, to the questions: Do you think this will work for Snow Leopard or Leopard? How would I even go about compiling QEMU user mode to the UEFI environment? Would any of you be willing to help me with this project? Thanks in advanced!

 

Again, I apologize if this is the wrong place to post this, and I also apologize for the lengthy post.

×
×
  • Create New...