UEFI Gentoo Quick Install Guide
It took me almost 2 days to figure out how to install and boot Gentoo on my new UEFI laptop.
I basically followed: http://www.gentoo.org/doc/en/gentoo-x86-quickinstall.xml
The following are points where I diverged from that guide in order to have a working, bootable system.
First, there is no master boot record on a UEFI system.
Instead your BIOS loads a .efi file from a FAT32 partition that you tell it about (by issuing a command to it's firmware, we'll get to that later)
Make sure efivars kernel module is loaded:
Here is how I created my partitions. NOTE the way I wrote the mkpart commands ensures proper alignment on SSD drives. Change them at your own risk. (Can use align-check to see if you did it right):
Now continue along with the quickinstall guide.
For the kernel configuration, make sure you specify the kernel options mentioned here: EFI stub kernel
Here are my steps:
Now the tricky part. In order to tell the BIOS about your new bootx64.efi, you need to have booted the system WITH UEFI.
Since you likely used a CDROM to boot the system, it is unlikely that you booted with UEFI. Sad face :(
What does work, is if you stick your new bootx64.efi file on a USB flash stick, the laptop will automatically find that and boot it.
So insert a USB stick, we'll pretend it comes up as /dev/sdd in the following code:
Now reboot the box and hit F2 (or whatever) to enter the BIOS on boot.
In the UEFI list, choose to boot the new USB flash stick that should be showing up.
The kernel should load up and boot your sytem.
Now you can tell the BIOS about your bootx64.efi that is on the hard drive:
Now enter the BIOS again and you should see "Gentoo" in the list!
Congrats, it should now boot!