Jump to content
InsanelyMac Forum
Sign in to follow this  

[Question] UEFI, EFI applications, rEFInd, OSx86... How to make them get along?

Recommended Posts

It takes a lot of time on Google for me to ask in a forum, I can't believe I'm the only single being this finnicky with his UEFI...


The point is: I already have a 2011 gaming PC, with ArchLinux as primary OS (for normal use) and Windows 8 (AKA gaming console mode). They are both working in UEFI/GPT mode, living along as good friends, sharing the same EFI system partition.


I'm bored with this, and I'd like to include OSX in the roster. Point is, I like to keep legacy stuff away. and I consider myself an early adopter. Ergo, I consider BIOS bootloaders legacy stuff. Reading about OSx86 I can only find Chameleon/Chimera (which I understand are basically the same software), Clover and the Darwin bootloader, which is the "actual" Mac loader. AND here lays the problem: as far as i know, Chameleon, Chimera and Clover all only emulate the MAC efi on a BIOS... I actually read someone suggest someone with a similar build to simply reinstall his windows in BIOS/MBR and screw the previous installation... what a brute. As if they couldn't be converted ;). Back to the question, what I want is, before wasting valuable money on an OSX license and bandwith on a DMG (I have no optical drives), to gather all the information about Chameleon/Chimera, Clover and the OSX boot process, including the actual secuence followed by either software, the files each write to the EFISYS partition, and the reason I haven't seen any reference to a .efi file or any kind of native EFI application. (Bold font added because I think I deviated too much :'D)


This last point is because, once UEFI started being used on PC's too, the simplest and most elegant method to solve the MAc EFI/PC UEFI differences would be to use a native UEFI application that would emulate (or pass the due variables, or whatever, this is why I'm asking) the Mac EFI to make the system even more vanilla.


My intention is to get rEFInd, which is a boot MANAGER, (not LOADER) to pass control as directly as possible to the Linux Kernel (which by itself is an actual EFI application), the Darwin bootloader (or a minimal build or setting for Chameleon/Chimera) or Windows (which must unfortunately be only loaded by the damned bootmgfw, the EFI version of Bootmgr)

Share this post

Link to post
Share on other sites

Hi and welcome,


currently only Clover supports UEFI mode and it can be started as an EFI application - meaning you wouldn't need to keep any legacy support enabled in your BIOS, if this is your aim.
However it won't recognize the EFI stub used by Arch Linux and this is where dmazar's patchset comes in handy. It allows the customization of menu entries and you can specify the loader and the arguments yourself.


You can read more about the boot process of Clover here.


The files written to the EFI partition are determined by the installation method you choose. You might want to extract and move them yourself to keep away anything you won't need.


I use the same setup myself by the way: Windows 8, Arch Linux and OS X.

Share this post

Link to post
Share on other sites

Obviously I didn't get very far when reading about Clover. I see this would be a feasible solution, but my goal is to have the smallest amount of software I can. If I can somehow patch Clover to have editable menu entries (which I supposed was possible), I could use it as the only bootloader, couldn't I? AFAIK it shares code with rEFInd, only I don¡t know the extent to which this happens.


Anyway, is it safe to assume that there is no simpler bootloader for Darwin? Is it really necessary to have a specific bootloader because of OSX? I was looking to keep something OS neutral (such as rEFInd) that would not really know anything about the OSes it boots (apart of what I tell it) and could be managed from every OS, in my case preferrably from Linux, but if I wanted I could force Windows to display the EFISYS partition and edit the settings, and presumably from OSX too (it's a FAT32 partition after all).


I read on the Clover patch you linked it's quite similar to rEFInd , because they share the original rEFIt codebase and the patch just "exposes" it's configuration. I previously understood that Clover was just another replacement for Chameleon/Chimera, but this proves me wrong. I'll investigate more about it and return if it doesn't fit my purpose :/



EDIT: In theory, I could just go and use Clover with no OSX installed, am I right? As in, directly replacing rEFInd or installing it by its side?

Share this post

Link to post
Share on other sites

Yes, you can have editable menu entries. This feature is not included in the trunk and is a custom modification made by one of the developers. A compiled binary is already available in dmazar's thread Maniac10 and I linked to. However it is made for an older revision and some configuration instructions mentioned in the wiki do not apply here. I can upload a copy of my Clover folder if you need.


As you already said, you can modify the content of your EFI partition from any OS. Additionally you can use an EFI shell before you boot an OS to - for example - move around files, which I personally find very handy.


I am really not an expert and can't list all the modifications done by an OS X compatible boot loader but the Clover wiki should give a good insight. They are not applied when booting another OS. You probably should ask at projectosx if you want to know more details. And yes, they are mandatory.


Clover alone will work just fine for your purpose. You only need to point it to the EFI loaders. Here is a part of my menu file for instance:

# OS X Mavericks
# Icons depend on OS X version, default is "mac".
menuentry_template "OS X Mavericks" {
    loader \System\Library\CoreServices\boot.efi
    ostype osx
    icon mac 10.8=cougar 10.9=mavericks
    submenuentry "Boot OS X in verbose mode" "${slide=0} -v"
    submenuentry "Boot OS X in safe mode" "${slide=0} -v -x"
    submenuentry "Boot OS X in single user mode" "${slide=0} -v -s"
    submenuentry "Boot OS X without caches" "${slide=0} -v NoCaches"
    submenuentry "Boot OS X without extra kexts" "${slide=0} -v NoKexts"
    submenuentry "Boot OS X without caches or extra kexts" "${slide=0} -v NoCaches NoKexts"

# Windows 8 EFI
menuentry_template "Windows 8" {
    loader \EFI\Microsoft\Boot\bootmgfw.efi
    ostype windows
    icon win

# Arch Linux EFI stub
menuentry_template "Arch Linux" {
    loader \EFI\ARCH\vmlinuz-arch.efi
    ostype linux
    icon arch
    options "root=PARTUUID=146429c0-2b2a-4851-b691-8edb3936b0a6 ro rootfstype=ext4 add_efi_memmap initrd=${Initrd} nomodeset"

Share this post

Link to post
Share on other sites

As far as I see the menu file (refit.conf if I'm not mistaken) is mostly identical to the rEFInd.conf , only the Clover one uses menuentry_template (why "template, though?) and submenuentries are in single lines, so I can see myself making the switch. I still have two doubts left: firstly, I don't see anywhere in the forum post k3nny linked any references to using icons other than the included and in ICNS format. I'll probably test it anyway, but one of tha main points of rEFInd is it's easy customization of these icons, and I have a couple PNG's I'd like to use. Shouldn't be hard to convert to ICNS and replace the included ones... I hope.


Second point: DSDT's are generally only mentioned when talking about OSX, but I observed a nifty feature in the Clover wiki: one of the values Clover may pass to the OS in the DSDT is the "PatchVBIos" key in the config.plist. The NVidia propietary graphics driver doesn't allow me to use my native monitor resolution outside of X11, and so virtual terminals and the boot splash are stuck in 1024x768, which gets horribly stretched in a 1920x1080 display... This key in the config.plist sets, in theory, the maximum resolution my monitor allows (according to it's EDID) in the Clover GUI... and all that comes after it. If a full DSDT is technically a standard feature of a motherboard, this should allow me to get the native resolution in the virtual terminals... and even in the Windows bootloader right? The only point remaining is if I can specify different DSDT's for each system...

Share this post

Link to post
Share on other sites

You can define the icon name in the according menu entry, e.g. arch and it will search for os_arch.icns. As far as I know only the Apple image format is supported.


PatchVBios is not related to DSDT but to the shadow video bios, which is patched. I'm not sure if it will help in this case but it surely is worth a try.


Clover can be configured to do many different things when it starts OS X but is a bit limited in its actions when booting another OS. I'm not sure if this option or a DSDT override for example are supported outside of OS X but you can very easily modify that part in the source code if it isn't.


As a side note, you can setup Clover on a thumb drive and test it without modifying your existing setup.


EDIT: Or not.. PatchVBios should only be relevant for legacy booting.

Edited by k3nny

Share this post

Link to post
Share on other sites

I find that the EFISYS partition is quite helpful when testing this kind of things and virtually removes the need to make backups and such of the (nonexistant) bootsectors or the partition: I can access the EFI Shell if I really, REALLY mess the boot options and boot linux manually to repair the options... so I'm not worried about ESB drives.


There is also the option to force a specific resolution with the ScreenResolution key... maybe this works. Anyway, as you said it's worth a try, so I'm going to try to set it up before start messing with OSX...




EDIT: Is it possible that as of Revision 1654 the dmazar patch is already in?

Share this post

Link to post
Share on other sites

I've found out that actually it is not included, so could you (k3nny) upload your folder as you offered? Apparently the build the patch is designed to work with didn't work and it can't be downloaded, only built from source and I can't seem to be able to find the way to do so on linux ><

Share this post

Link to post
Share on other sites

Well... that's the files the linked post provide. Should I assume then that they should work as-is with the latest revision?

Share this post

Link to post
Share on other sites

No, they won't. In comparison to the revision I uploaded previously, the recent revisions have undergone several changes affecting the configuration file structure and options.

Instead you can use my Clover folder, it includes all necessary files. You only need to set up Clover as a boot option (see 5.2).

Share this post

Link to post
Share on other sites

But what you uploaded is just the same zip in the dmazar's thread unless I really messed up, and that's only the main EFI binary, a sample refit.conf, the EXT4 EFI driver and the diff file for Clover r1341, which I cannot obtain unless I build from source and I can't without an already working OSX as far as I know. What I thought you would upload was a full 1341 build with the additional files.


The reason I can't download r1341 is because apparently it didn't even run, and so there are no public builds in sourceforge.

Share this post

Link to post
Share on other sites

Not every revision is uploaded on SF. It works fine and you should be able to build it from Arch, if you really want to - try following the wiki instructions.


I uploaded a full build, check it again.

Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.

  • Similar Content

    • By frankiee
      Hi there, time for my first guide after asking so many things
      Updated for newer Clover versions and with additional instructions for more apps: gdisk and RU.
      So what may be overlooked sometimes in the whole boot loader discussion is the ability of UEFI to do more than just loading an OS. This is why I see ".efi" files as "apps" because in fact they just are, built on a special kind of API: UEFI. So, you can actually do stuff like editing, diagnosing, testing certain stuff at the lowest possible system level without booting to any OS.
      DISCLAIMER: Use this guide at your own risk! For educational purposes only! Should do not any harm, but remember you are dealing with rather low level stuff. But at least for me everything went flawless.
      Working clover installation Clover Configurator or some app to edit the config.plist  
      1) Memtest
      This is how to install the UEFI version of Memtest with Clover:
      Download memtest, I used this link: Image for creating boot-able USB Drive Open the archive by double clicking on it. Mount the file memtest86-usb.img within by double clicking again. Now, you should see a folder named EFI in this volume, containing a folder BOOT. Open it. The files containing it are the actual app, in 32 and 64 bit versions. Think in almost all cases we want to use the 64 bit version. Now, mount your EFI partition, using Clover configurator. Create a folder named MemTest86 in the EFI folder on your main drive. Copy all files in the EFI/BOOT folder from the mounted image to your newly created folder. That ends the basic setup! Now, we add the correct Menu entry to the clover boot menu, so that we can actually start this app.
      Get into clover configurator, open your standard config.plist from your boot drive and go to the GUI section. Under "Custom Entries", add an entry like this:

      Please note while the path you enter is not case sensitive, you must make sure you use the backslash "\" for entering paths, and not a slash. So basically what we do is tell clover where it can find the app, give it a name, and tell clover it is a "Windows" app. Note: with older Clover versions we had to set this to "Linux", but for now "Windows" is the setting that works.
      If you prefer to do a manual config, add this entry to your config.plist, under GUI/Custom/Entries:
      <dict> <key>CustomLogo</key> <true/> <key>Disabled</key> <false/> <key>FullTitle</key> <string>MemTest86</string> <key>Hidden</key> <false/> <key>Ignore</key> <false/> <key>Image</key> <string>\EFI\CLOVER\themes\Icons\os_mint.png</string> <key>Path</key> <string>\EFI\MemTest86\BOOTX64.efi</string> <key>Type</key> <string>Windows</string> <key>VolumeType</key> <string>Internal</string> </dict> Now, save and reboot and you should see the newly created entry. Note that I also used a custom Icon - this is optional - in case you don't you will just see a generic windows icon instead:

      And this is how it looks like:


      PS: also noticeably faster and you get also more features with this version than with the older version, for example it does now write a log file. For more Information, see: http://www.passmark.com/forum/showthread.php?4315-Memtest86-Version-5-Beta-%28Pure-UEFI%29
      2) gdisk
      Another app you can use is the UEFI version of gdisk (aka GPT fdisk), which you can use to edit and change your partitions.
      Warning! Install and use this app at your own risk! If you do something wrong here you might nuke your drive(s), so only use that if you know what you are doing.
      This is how to do it (even easier):
      Download here: https://sourceforge.net/projects/gptfdisk/files/gptfdisk/1.0.1/gdisk-binaries/gdisk-efi-1.0.1.zip/download Mount your EFI partition Unzip the file and copy the resulting folder to your EFI Folder, so your path goes like this "/Volumes/EFI/EFI/gdisk-efi" Get into clover configurator, open your standard config.plist from your boot drive and go to the GUI section. Add an entry like this:  
      If you prefer to do a manual config, add this entry to your config.plist, under GUI/Custom/Entries:
      <dict> <key>CustomLogo</key> <false/> <key>Disabled</key> <false/> <key>FullTitle</key> <string>GDisk</string> <key>Hidden</key> <false/> <key>Ignore</key> <false/> <key>Image</key> <string></string> <key>Path</key> <string>\EFI\gdisk-efi\gdisk_x64.efi</string> <key>Type</key> <string>Windows</string> <key>VolumeType</key> <string>Internal</string> </dict> When everything went OK you should see this after selecting the respective entry in Clover:

      3) RU
      I recently found one more app that might be interesting to some, and thats "Read Universal" or in short "RU". This is a tool that enables you to debug your BIOS and read (and modify!) every imaginable data, including UEFI variables, ACPI Tables etc.
      Warning, again! I think blindly messing around with this app is even more dangerous, but on the other hand it gives you access to a lot of potentially interesting stuff.
      Download here: http://ruexe.blogspot.de/ The next steps are basically the same as above so make a folder in your EFI partition, copy the .EFI files and make another custom entry in your config.plist Here are some screens:



      So this is what you also can do with UEFI and clover. I am curious which other useful applications might exist!
      Anybody who knows, maybe post it here?
    • By partha.slg123
      Hackintosh High Sierra 10.13.3 USB Installer Boot Into USB DIrectly Enter Exit Option Menu. Clover Boot Menu Not Showing. Plz Help .................

      My System Specification :

      CPU : Core i5 6400
      MB : Asus H110M-CS
      RAM : 8GB DDR 4
      HDD : WD 1TB For Windows And WD 500 GB For Hackintosh
      Bootloader : Clover
    • By Soeren_DK
      Hi there.
      I'm new to this site but not totally new to hack. I've had a hack since 10.4 and the latest version I ran was 10.9, not totally fixed but it worked to what I needed. Now I want to make the machine run as good as it can. I can see there has been a lot of changes/upgrades/new solutions since I installed my hack and I have a hard time to catch up.  
      I've been able to boot and install macOSX and now I need the POST installation.
      I tried to install the clover EFI boot loader with these settings:
      and found the DSDT.aml and SSDT-0.aml from HERE
      found the apfs.efi
      and placed it in EFI -> EFI -> CLOVER -> driver64
      and these kext in here:

      But when I boot it up this is the first bootscreen I have. No partions, no mouse control, no nothing.

      if I exit clover this screen appear.

      and now everything works. 
      What is wrong?
    • By glasgood

      ASUS  STRIX Z370-G ROG
      ( Micro-ATX )
      ** UPDATE  5th Jan 2018  /  Clover v2.4k r4359 **
      Great YouTube Hackintosh Installation Guide from >> Roberto Jorge <<  based on this post.
      Asus ROG Strix Z370-G Gaming (Wi-Fi AC) ( Micro ATX )  i7 8700 3.2GHz  Corsair Vengeance LPX 8GB (1 x 8GB) DDR4 DRAM 2400MHz (PC4-19200) C14 Memory Kit - Black  Samsung Evo 960 250GB NVMe SSD  NVIDIA GeForce GTX 1080ti (or a GTX 1050 / 1060 / 1070 will work  ) ABWB 802.11AC WI-FI with Bluetooth 4.0 PCI-Express  BitFenix Phenom – Tower – micro ATX  Noctua NH-L9x65 - NH-L9x65 Low Profile Performance CPU Cooler  EVGA SuperNOVA 750 G3, 80 Plus Gold 750W  Corsair UK K65 Rapidfire Cherry MX Speed Performance Multi-Colour RGB Backlit 10 Keyless  Samsung 850 EVO 500GB  Dell UltraSharp U2717D (2560x1440DP) IPS LED 27-Inch Infinity Edge  
      Wi-Fi ( Onboard WiFi card was replaced, see components list above )   Bluetooth Ethernet Port Sound --> Nvidia HDMI Audio and Realtek Audio NVMe 960 EVO / Trim Nvidia GTX 1080ti i7-8700 ( six-physical cores and 6 virtual - HT ) Intel UHD630 (configured with DisplayPort attached to Asus board) 8. Sleep Power Management and P-States         USB 3.0 USB 2.0 HandOff AirDrop iMessages iCloud Hardware Acceleration AirPlay iBooks Personal Hotspot  

       F2 to enter BIOS on Asus Z370 Strix 2 - Switch to Advanced Mode F7  

      Some of the settings already preset, ensure you have the following BIOS settings:
      Exit → Load Optimized Defaults : Yes Advanced \ System Agent(SA) Configuration → Vt-d : Disabled Advanced \ PCH Configuration → IOAPIC 24-119 Entries : Enabled Advanced \ APM Configuration → Power On By PCI-E/PCI : Disabled Advanced \ Network Stack Configuration → Network Stack : Disabled Advanced \ USB Configuration → Legacy USB Support : Auto ( needs to be auto for SSDT-UIAC.aml to work ) Boot → Fast Boot : Disabled Boot → Secure Boot → OS Type : Other OS Boot → CSM : Disabled ( Only enable if using dual monitor setup) Ai Tweaker → Asus MultiCore Enhancement: Disable ( but only if you have intel stock CPU cooler ! )  
      See spoiler for BIOS Screenshots.
      Advanced \ System Agent(SA) Configuration → Primary Display : Auto Advanced \ System Agent(SA) Configuration → iGPU Multi-Monitor : Enabled OR
      Integrated Graphics : Enabled iGPU MultiMonitor : Enabled DVMT Pre-Allocated : 128Mb 4. Primary Display : Auto  
      When running the installer the memory modules must be inserted in motherboard slots A1 and A2, otherwise you will be unable to run the installer.

      Download High Sierra from the Apple App Store  
      Prepare USB Flash Storage Pen

      Insert USB Storage Launchpad / Other → Disk Utility Choose your Flash Storage Pen from left panel Click Erase Settings: Name: USB Format: Mac OS Extended (Journaled) Scheme: GUID Partition Map Click Erase
      Create  macOS High Sierra Installer

      Launchpad / Other → Teminal Copy and Paste into Terminal:  sudo /Applications/Install\ macOS\ High\ Sierra.app/Contents/Resources/createinstallmedia --applicationpath /Applications/Install\ macOS\ High\ Sierra.app  --volume /Volumes/USB/ Press: Enter Enter password: Type: Y Press: Enter Done!   

      You have now created the macOS High Sierra Installer. In order to boot and install macOS onto your computer the installer requires the Clover boot loader from Clover team.
      The Clover boot loader contains, a configuration file ( config.plist) and kernal extensions (kexts), the config.plist and kexts are specific for each Hackintosh desktop / laptop computer build. Clover boot loader also has many other files and folders. 
      I have already prepared a USB drive using the Clover installer  and made edits to config.plist for this build, you can download and copy over my EFI  Folder and skip steps in Spoiler below,  then paste the downloaded EFI folder in the hidden USB EFI / ESP partition on your High Sierra USB installer drive. 
      See the spoiler, using Clover installer to make High Sierra USB installer bootable.
      View the hidden macOS High Sierra Installer's EFI/ESP partition 
      Open Terminal Copy and Paste into Terminal:  diskutil list Enter
      Mount the USB EFI / ESP Partition onto the Desktop

      Again, from Terminal. Copy and Paste into Terminal: 
        diskutil mount disk3s1 ** Identify your EFI partition from diskutil list command, in the example image above my external  USB EFI is listed as disk3s, yours maybe different ** 3.  Enter.
      The hidden EFI / ESP partition is now mounted on your desktop.

      Copy EFI Folder to USB EFI / ESP Partition
      ( Don't use the post install EFI folder at top of page, use post install EFI only after macOS High Sierra is installed ) 
           1.   Download the PRE INSTALL  EFI Folder here >> EFI.zip

            2.  Drag & Drop or Copy & Paste downloaded EFI folder into the mounted USB EFI / ESP partition.

      The bootable USB installer for macOS High Sierra is ready to use!
      Insert  the macOS High Sierra USB Installer into computer USB port. Start PC and immediately press keyboard F8. From Asus Boot Menu, choose your USB thumb drive.
           4.  Clover boot menu 
          5.  Choose - Boot OS X install from Install macOS High Sierra..

      Later in the guide, I will explain how to remove the extra entries on the boot menu, so you would have just High Sierra Icon and / or Windows. The extra entries are removed in config.plist in the uploaded EFI / Clover folder that I have provided.
           6.  Wait few mins!

            7.  Choose Languge

            8.  Select Disk Utility

           9.  From Disk Utility Menu --> View / Show All Devices

          10.  If Samsung 960 EVO drive is not visible in Disk Utility, follow these steps inside spoiler below. 
         11.  Erase, disk. Give Name / Format: Mac OS Extended ( Journaled) / Scheme: GUID Partition Map

          12.  Partition, Format: APFS and apply 


          13.  From macOS Utilities screen select Install macOS

          14.  Continue 
          15.  Agree

          16.  Select Drive Macintosh or whatever you named it.

          17.  macOS is now installing

          18.  Wait...
          19.  Success !
      So far, you are using the macOS High Sierra USB installer to boot High Sierra. The USB installer EFI /ESP partition contains the downloaded EFI / Clover folder allowing you to boot to High Sierra desktop.  So at this moment you can only boot High Sierra with the help of Clover on the USB installers hidden EFI / ESP partition.  Next, steps is to make High Sierra boot without the need of the USB installer.
      Copy POST EFI folder to your High Sierra EFI / ESP Partition on your drive
      When you created the USB High Sierra installer, you mounted the EFI / ESP partition and copied over the EFI folder that I provided for the Asus  Z370-G.
      Next, mount the hidden EFI/ESP partition on your High Sierra system drive.
      Then copy the >> or POST EFI folder to your macOS High Sierra system drive . To do this, follow steps below.

          1.  Identify discs to Mount with Terminal command:
      diskutil list
      ** Your disk IDENTIFIER may be different, the images are examples from my system **
          2.   Terminal command below to Mount macOS EFI/ESP partition:
      diskutil mount disk0s1     3.   System drive, EFI / ESP partition is mounted on desktop
          4.   Drag & Drop OR Copy & Paste EFI / ESP folder from EFI - POST-INSTALL   over to EFI / ESP drive partition:

          5.   Done!
      You can now boot and use macOS High Sierra on your computer without the need for the USB device 
      Mostly everything should now be working if you used the same hardware that I listed in parts.
      In the rest of this guide will explain some basic troubleshooting steps, how install NVIDIA web drivers, how sound was installed.. etc.
           1.   You need to mount the EFI / ESP partition to edit the Clover config.plist.
      Previously, the guide used teminal commands diskutil list and diskutil mount to mount hidden EFI/ESP partitions.
      This guide will now use an app to mount the EFI / ESP partition.

      Download @Micky1979 >>ESP Mounter Pro on InsanelyMac and use it to mount the EFI / ESP partitions so that you can view, make edits to config.plist, add extra kexts if needed etc.

      A quick peak at the EFI / Clover contents, highlighting most common files and folders.

          2.   Download >> Clover Configurator  from mackie100, it is used to edit and make changes to config.plist.     

      Open mounted EFI partition, navigate to EFI / Clover, make a copy of config.plist and rename it config.BAK.
      Then drag and drop conf.plist onto desktop. Make changes, save and drag & drop back inside EFI partition.

      Clover Configurator default screen, always save before quitting Clover Configurator!

      Some people will be very familiar with how to find and configure config.plist, I'm listing this guide with extra steps for those new to Hackintosh.
      You might make changes to config.plist with Clover Configurator or add kexts and then discover that you can no longer reach High Sierra desktop or boot.
      The USB installer can be used to boot your Hackintosh ( I mentioned it was a handy troubleshooting tool ). The USB installers Clover boot loader can boot your computer to the High Sierra desktop. You can then mount the EFI/ESP partition and undo config.plist  edits or delete last added kexts that have prevented you from booting to your High Sierra Desktop or just replace the whole EFI folder on your computer with the EFI folder from the USB installer.
      If the above troubleshooting was unsuccessful and you still can't boot your Hackintosh.
      From the Clover boot  screen, enter Clover options:
      Select Boot macOS from Macintosh  Then press spacebar Check: Verobse (-v) Return Enter  
      The Verbose (-v) option will point to where in the startup process your Hackintosh stops, it's also worth checking BIOS settings before starting any troubleshooting. 
      You can then search in the InsaneleyMac forums for a solution, or ask other members. 

      Sometimes when troubleshooting or installing kexts, you may have to disable Apple System Integrity Protection ( SIP ). 
      To disable or enable SIP, mount the EFI / ESP partiton using ESP Mounter Pro or Terminal then edit config.plist with the Clover Configurator.
      Example: Disable SIP in Clover Configurator:

      Rt Variables / CsrActiveConfig --> Enter: 0x67  Partially disable: Rt Variables / CsrActiveConfig --> Enter: 0x3 ( Clover Default )  Enable: Rt Variables / CsrActiveConfig --> Enter: 0x0  
      Clover adds extra MacOS and Windows entries on the Clover boot menu. Below is what my Clover menu initially looked like after installing Mac OS High Sierra and adding a Windows drive to my build.
      The High Sierra Clover theme is from >> hirakujira

      I wanted the Clover boot menu to just show Mac OS High Sierra and Windows.
      Remove extra entries using Clover Configurator
      Add the Preboot string to config.plist    ( Removes Apple Preboot entries ) Add theRecovery string to config.plist   ( Removes the Mac OS High Sierra recovery option ) Set Scan / Legacy checkbox to false in config.plist   ( Removes the extra Windows entries )  

      After applying the settings in Clover Configurator, save and reboot.

       Minimalist Clover boot screen. 
      Temporarily disconnect / remove your High Sierra Drive from your Hackintosh Computer. Install a 2nd drive inside the computer then install Windows on it. Reattach your High Sierra Drive. Clover will detect your Windows and High Sierra drive when you start your computer.  
      I already had Windows 10 as an EFI install on a Samsung 500GB EVO SSD on another computer. After completing my Hackintosh I then simply attached the Samsung EVO SSD into the new built Hackintosh. Upon rebooting it was detected by Clover. So I have two drives, Windows on the Samsung EVO and High Sierra on the NVMe Samsung EVO 960.
      *** There is many Nvidia Web Drivers for different builds / updates of macOS High Sierra ***
      Some times you may have to reinstall or update your Nvidia web drivers after a macOS update.
      To install the proper Nvidia Web driver ( for GTX10 Series ),  collect the following information from your macOS High Sierra installation.
      You can find this information in "About This Mac" and clicking on the System Report button. In the lefthand window, click on Software.
      macOS High Sierra Version Number macOS High Sierra Build Number
      Using this >> Nvidia Web Drivers Link. identify your build number and download WebDriver  As an example, I have build number 17C88 and I downloaded WebDriver-378. 

      Configure Nvidia Web driver in config.plist using Clover Configurator
      Mount EFI partition and drag and drop config.plist onto desktop and open with Clover Configurator. 
      Enable the following in config.plist:
           1.  System Parameters / NvidiaWeb = True ( tick )

           2.  Graphics / ig-platform-id = 0x59120003 ( Intel & Nvidia )
           3.  Graphics / Inject Intel = True ( tick )

      Save config.plist and drag and drop back into the EFI partition.
      Check Nvidia Video card is working

      Download and Install >> Cuda driver 
      Managing Nvidia Web Driver for High Sierra update's using Vulgo's Bash Script
      If you have installed an update that breaks Nvidia graphics, use the bash script to modify the Nvidia Web Driver for the new build number. 
      Download >> webdriver.sh
      Run script: 
      Configured with display cable connected to DisplayPort
      Download >> IntelGraphicsFixup ( from lvs1974 ) Copy IntelGraphicsFixup.kext to: EFI/Clover/kexts/Other Next add the iGPU DSDT patch:
      Using Clover Configurator, open config.plist Select Acpi on left hand menu. Create a new patch, click + on bottom of patches table.  Enter Comment as: change GFX0 to IGPU Enter Find *[HEX] 47465830 Enter Replace *[HEX] 49475055
      Then add:
      Select Graphics in Clover Configurator and tick inject Intel Graphics / ig-platform-id = 0x59120000 ( for Intel only and no NVIDIA )
      Download and install ( drag & drop ) in EFI / Clover / Kexts / Other folder
      AppleALC.kext ( from vit9696 ) Lilu.kext. ( from vit9696 ) CodecCommander.kext ( from RehabMan ) Edit config.plist with Clover Configurator.
      Devices / Audio Inject= 1. ( Asus Strix layout is 1, different Motherboard and audio chip ? -->supported codecs ) ResetHDA = True ( checked ) Acpi / Fixes / FixHDA = True (checked)

           4.  Look in System Report to confirm working
      Enable Nvidia HDMI Audio 
      Thanks again to MaLd0n here on InsanelyMac for explaining and patching the VoodooHDA.kext with my Nvidia graphics card device ID. 
      For Nvidia HDMI Audio, use VoodooHDA.kext, and keep AppleALC for ALCS1220A audio in kexts / other folder
      Patch VoodooHDA
      Download >>VoodooHDA.kext ( from autumnrain, slice2009, zenith432 ) Download >> DPCI Manager Right Click on VoodooHDA.kext and Show Package Contents Open Info.plist with Xcode  Finds IOKitPersonalities / VoodooHDA /  IOPCIClassMatch Change IOPCIClassMatch to IOPCIPrimaryMatch Use DPCI Manager to find  Device & Vendor ID's for your Graphics card ( example, NVIDIA GTX 1080ti the value is 0x10ef10de ) Insert the value for your NVIDIA Card Place patched VoodooHDA.kext in EFI /Clover /Kexts / Other folder
      Sound before Patch:

      Sound after Patch:


      Ports fix Is required for potential ports conflicts and bugs with sleep, restart and shutdown.
      Continuing to use the port limit patch can cause problems as it causes access outside a fixed array bounds. 
      Access outside a fixed array bound can result in other memory locations being overwritten, those other memory locations will contain data that you don't won't overwritten!. So the port limit patch is not recommended for long term use. Ports limit patch is good for macOS USB installer purpose. Ports limit patch is disabled in my POST INSTALL EFI folder.
      Below is the USB ports limit patch shown in clover configurator:

      Note, external 2x USB2 ports HS09 and HS10 are deliberately disabled to get port count below 15.
      If you have a different motherboard you can use IORegistryExplorer for port discovery and eliminate some ports to get below the 15 port limit. You can create an SSDT for port limit to use with USBInjectAll.kext. Or, If you are not keen on creating the SSDT file, then you can use "uia_exclude=" boot flag in config.plist and have USBInjectAll.kext exclude those ports.
      Rehabman has a great guide on port discovery & SSDT. >>Creating a Custom SSDT for USBInjectAll.kext
      When you know what ports you want to eliminate, then you would set custom boot flags using "uia_exclude=" in config.plist.  USBInjectAll.kext would then ignore those ports listed by "uia_exclude=" boot flag.
      Example: using "uia_exclude=" boot flag to keep USB port below 15
      If you have Asus Z370-G as per this guide then don't use custom boot flags  as it's already done with SSDT-UIAC.aml
      Disable Ports Limit Patch:

      My ABWB 802.11AC WI-FI with Bluetooth card is installed in motherboard slot: PCIE_X1_2 
      the ABWB 802.11AC WI-FI with Bluetooth card USB cable is attached on internal USB1112 header (HS12) on the motherboard.
      If you have a Wifi card with Bluetooth in a  different PCIE slot then remove SSDT-UIAC.aml from 
      EFI/CLOVER/ACPI/PATCHED and download SSDT-UIAC-ALL.dsl and change HS12 for appropriate port and save 
      SSDT-UIAC-ALL.dsl as ACPI Machine Language Binary and place file in EFI/CLOVER/ACPI/PATCHED.

      This worked for me on my first attempt, I suggest using an Apple WiFi  card for hassle free iMessages etc...
      I'm using an original >> Apple BCM943602CS WIFI+bluetooth module and adapter, this has native support in macOS High Sierra and needs no kexts / drivers. It works out of the box! 
      If you can't get a hold of this card used in this build, then try sourcing a PCIe adapter and fitting an iMac WiFi card to it.
      Purchase adapter on >> Ebay or Amazon 
      Apple iMac WiFi card, part Number >> 607-8967

      Or use a MacBook Air WiFi card & adapter, it would directly replace the Asus Wifi card and free up PCIe slots.

      Configure iMessages with the Clover Configurator
       SMBIOS / Generate New SMBIOS Profile for iMac 18,3  Check >> Serial number generated is not in use!"
           3.   System Parameters / Custom UUID ( Generate New )

           4.    Rt Variables / ROM ( Generate from SMBIOS or System )

      Windows drivers for Apple WiFi and Bluetooth devices.
      If you are dual booting with Windows and you are using an Apple WiFi / Bluetooth card like the one suggested above.
      Then chances are you won't have Windows drivers. 
      The drivers can be obtained by downloading Windows support from Bootcamp.
      Launchpad / Other ---> Bootcamp Assistant.  
      "About my Mac" will show CPU as unknown.

      Fix :
      Download >>TextWrangler ( use Text Wrangler, as other editors output code differently )
           1.    Copy and paste command into Terminal to open English.lproj directory:
      open . /System/Library/PrivateFrameworks/AppleSystemInfo.framework/Versions/A/Resources/English.lproj/
            2.   Edit AppleSystemInfo.strings using Text Wrangler.


       Edit from:
      <key>UnknownCPUKind</key> <string>Unknown</string>          Edit to:
      <key>UnknownCPUKind</key> <string>3,2 GHz Intel Core i7-8700(6-Cores)</string>
      There is now no need for ssdtPRgen.sh generated SSDT.aml for Haswell CPU and newer. 
      Power management can be configured in config.plist with Clover Configurator.
      Acpi / Generate Options / PluginType = True ( tick )
           2.  Boot / Argument / -xcmp = True ( tick )

      Test Power Management using Piker-Alpha's AppleIntelInfo.kext
      Compile source or >> download >> AppleIntelInfo.kext.zip 
      Use AppleIntelInfo.kext as per Piker-Alpha's  >> instructions
      1. Save AppleIntelInfo.kext to desktop.
      2. Using Terminal and change directory to Desktop
      cd Desktop/ 3. Enter following commands and press Enter.
      sudo chown -R root:wheel AppleIntelInfo.kext sudo chmod -R 755 AppleIntelInfo.kext sudo kextload AppleIntelInfo.kext 3. View output
      sudo cat /tmp/AppleIntelInfo.dat sudo kextunload AppleIntelInfo.kext

      Using ESP Pro or Terminal, mount EFI / ESP partition and place kexts RehabMan-FakeSMC-2017-1017 package into Clover / Kexts / Extra folder. Shutdown and restart computer. Copy and Paste HWMonitor App to Applications / Utilities.
      Download >> RehabMan-FakeSMC-2017-1017 package ( from RehabMan )

      Any  unrecognised System Memory ( Dual Channel setup etc ) can easily be set with the Clover Configurator.

      Make Backup
      1. Download and install >> Carbon Copy Cloner CCC5 
      2. Attach an external USB drive.
      3. Use Disk Utility and format external drive, create GUID partition map and APFS volume named Hackintosh.
      *Give Backup a different name from your main system drive to avoid confusion when performing a restore. So, my drive is Macintosh & backup is Hackintosh *

      4. Open Carbon Copy Cloner.
      5. Set Source as your High Sierra system drive, my drive is named Macintosh.
      6. Set Destination as your external USB drive named Hackintosh.

      7. Click Clone button.
      Restore Backup
      1. Attach macOS High Sierra Installer USB drive.
      2. Attach external USB backup drive that contains the bootable backup you made.
      3. Boot PC and press F8 and boot from external macOS High Sierra Installer USB drive.
      4. From Clover boot menu choose Boot macOS from Hackintosh.

      5. It may take a few minutes to boot High Sierra from your external USB drive.
      6. Launch Carbon Copy Cloner.
      7. Source should be external USB drive named Hackintosh.
      8. Destination should be your High Sierra installation drive. I named my drive Macintosh. 

      9. Click Clone button.
      Test Backup
      1. Follow steps 1 to 4 from Restore Backup.
      Thanks to MaLdon for taking the time to produce the DSDT for the Asus Strix Z370-G, the list of the patches can be viewed at the download link below.
      ** Only use the DSDT if you have the Asus Z370-G Strix Motherboard with BIOS update ver 0430 **
      Download DSDT here from >> MaLd0n  Place DSDT.aml inside EFI / Clover / ACPI / patched folder Open config.plist with Clover Configurator In Clover Configurator  Acpi /  Generate Options / set PluginType as False ( no check ) Reboot computer System Report before:

      System Report after:



    • By ErmaC
      This is EFI-based bootloader for BIOS-based computers created as a replacement to EDK2/Duet bootloader http://www.tianocore.org.
      To compile it needs to place Clover sources into edk2/ folder.
      using UEFI BIOS or own CloverEFI
      default boot after timeout into previous chosen OS
      customizable GUI: themes support, own icons, fonts, background image, animated pictures, mouse pointers.
      F1 - multilingual help, depending on language in config
      saving preboot.log from GUI by typing F2 and system.log for debug
      save original (OEM) ACPI tables by pressing F4
      test DSDT patching with F5
      save videoBIOS into EFI/misc by pressing F6
      saving screenshots from GUI typing F10
      CD/DVD eject by F12 and refresh menu after CD insertion
      change GUI resolution by PgUp/PgDown
      save BOOT0000 option to NVRAM (like bcfg in Shell)
      call to Shell.efi
      native screen resolution in GUI
      scroll bar if screen resolution is too low for menu
      theme database http://clover-wiki.zetam.org/Theme-database
      Clover wiki: http://clover-wiki.zetam.org/Home
      Clover on ProjectOSX : http://www.projectosx.com/forum/index.php?showtopic=2562
      Clover on InsanelyMac: http://www.insanelymac.com/forum/forum/327-clover/