n.d.k Posted November 26, 2019 Share Posted November 26, 2019 (edited) OC forked https://github.com/n-d-k/OpenCorePkg. Additional features/changes: ============ [ Multi-Boot ] - ACPI patches and Booter Quirks are optional for non macOS with setting ACPI->Quirks->EnableForAll / Booter->Quirks->EnableForAll to yes (default is no). - SMBIOS and Device Properties patches will only applied to macOS. [ Hotkeys ] - Full functional Hotkeys [1-9] corresponding to Boot Entry's Index number and dedicated W (Windows) / X (macOS) keys can be used without seeing Boot Picker. - While in boot picker, F10 can use to take a snapshot of the screen. [ Ui Boot Picker ] - Bios Date/time, auto boot to the same OS or manual set to always boot one OS mode, and OC version are displayed in boot picker. - Auto boot to previous booted OS (if Misc->Security->AllowSetDefault is NO/false). - macOS Recovery/Tools Entries are hidden by default, use Spacebar/Mouse click right in Boot Menu as a toggle on/off to show/hide hidden entries. - Mouse supported. [ Custom Entries ] - Custom entries are now listed first in picker menu and by the orders they are appeared in Misc->Boot->Entries, before all other entries. - Ability to change entry name found by auto scanner by adding custom entry with the exact same device path, this will give users the option to complete change how all boot entries listed in Boot Picker. [ Others ] - No verbose apfs.efi driver loading (if using apfs.efi instead of ApfsDriverLoader.efi). - ndk-macbuild.tool script are set to compile with latest edk2 (One can easily set to stable edk2 if prefer). Usage: - To build OpenCore, run "./ndk-macbuild.tool" at Terminal (require Xcode and Xcode Command Line Tool installed, and open xcode to accept license agreement before compiling). 4k light theme 4k dark theme. Edited April 4, 2020 by n.d.k 8 6 Link to comment Share on other sites More sharing options...
Ellybz Posted December 17, 2019 Share Posted December 17, 2019 (edited) Brilliant add-ons. Thanks. Any chances to get the entries in the OC boot picker to show based on the chronological order they appear in Misc/entries? Ex : 1- Mojave /2- Catalina/3- Windows/4- Linux VS 1- Catalina /2- Mojave/3- Windows/4- Linux, etc... Edited December 17, 2019 by Ellybz Link to comment Share on other sites More sharing options...
n.d.k Posted December 18, 2019 Author Share Posted December 18, 2019 (edited) 9 hours ago, Ellybz said: Brilliant add-ons. Thanks. Any chances to get the entries in the OC boot picker to show based on the chronological order they appear in Misc/entries? Ex : 1- Mojave /2- Catalina/3- Windows/4- Linux VS 1- Catalina /2- Mojave/3- Windows/4- Linux, etc... TBH, I set my showpicker to off and used hotkey w and x to switch between Windows and macOS without having to see boot picker at all. I gave the boot pickers some mods because it was too simple. But i'll add your suggestion into the to do list. Edited December 18, 2019 by n.d.k 1 1 Link to comment Share on other sites More sharing options...
Andrey1970 Posted December 23, 2019 Share Posted December 23, 2019 Please don't write a bugreports in acidanthera if you use this fork. 1 1 Link to comment Share on other sites More sharing options...
n.d.k Posted December 23, 2019 Author Share Posted December 23, 2019 On 12/17/2019 at 4:54 PM, Ellybz said: Brilliant add-ons. Thanks. Any chances to get the entries in the OC boot picker to show based on the chronological order they appear in Misc/entries? Ex : 1- Mojave /2- Catalina/3- Windows/4- Linux VS 1- Catalina /2- Mojave/3- Windows/4- Linux, etc... This is done! in last commit. 2 1 Link to comment Share on other sites More sharing options...
n.d.k Posted December 23, 2019 Author Share Posted December 23, 2019 5 hours ago, Andrey1970 said: Please don't write a bugreports in acidanthera if you use this fork. And Please don't write anything here that are not related to the modification of this fork. 6 Link to comment Share on other sites More sharing options...
texem Posted December 27, 2019 Share Posted December 27, 2019 any chance selectively enable/disabling SMBIOS patching if booting into other OS ? Link to comment Share on other sites More sharing options...
n.d.k Posted December 27, 2019 Author Share Posted December 27, 2019 5 hours ago, texem said: any chance selectively enable/disabling SMBIOS patching if booting into other OS ? Is there any benefit if it is an option? or any potential issue while it is not? 1 Link to comment Share on other sites More sharing options...
texem Posted December 27, 2019 Share Posted December 27, 2019 AFAIK clover doesn't touch smbios but OC does. No idea if this is an potential issue but win believes it's running on a mac. 1 Link to comment Share on other sites More sharing options...
n.d.k Posted December 28, 2019 Author Share Posted December 28, 2019 6 hours ago, texem said: AFAIK clover doesn't touch smbios but OC does. No idea if this is an potential issue but win believes it's running on a mac. It's good thing that Windows and other Oses are running on anything regardless mac hardware or not, unlike restricted OSX. So, just let it be for now. 1 1 Link to comment Share on other sites More sharing options...
Slice Posted December 28, 2019 Share Posted December 28, 2019 Windows will be better to run on real hardware then fake hardware. 5 2 Link to comment Share on other sites More sharing options...
moozuki Posted December 28, 2019 Share Posted December 28, 2019 After having to reinstall windows due to OC patching causing kernel errors, I have stopped using OC to boot windows. I now just use the bios boot selector (f12). Link to comment Share on other sites More sharing options...
mhaeuser Posted December 28, 2019 Share Posted December 28, 2019 16 hours ago, texem said: AFAIK clover doesn't touch smbios but OC does. No idea if this is an potential issue but win believes it's running on a mac. Nobody should introduce features or "fixes" just for the sake of introducing features or "fixes" 9 hours ago, Slice said: Windows will be better to run on real hardware then fake hardware. I'm sure you have sources and/or references for that? Link to comment Share on other sites More sharing options...
texem Posted December 28, 2019 Share Posted December 28, 2019 38 minutes ago, Download-Fritz said: Nobody should introduce features or "fixes" just for the sake of introducing features or "fixes" This answer is really very helpful. Thanks 1 hour ago, moozuki said: After having to reinstall windows due to OC patching causing kernel errors, I have stopped using OC to boot windows. I now just use the bios boot selector (f12). Are you talking about this fork or origin OC ? Link to comment Share on other sites More sharing options...
Slice Posted December 28, 2019 Share Posted December 28, 2019 4 hours ago, Download-Fritz said: I'm sure you have sources and/or references for that? I said "will be better". Link to comment Share on other sites More sharing options...
n.d.k Posted December 28, 2019 Author Share Posted December 28, 2019 14 hours ago, Slice said: Windows will be better to run on real hardware then fake hardware. I don't know if it's a glitch with previous version of AMD software or the cause of using Mac HW identity, it refused to upgrade my Rx580 driver due to no compatible graphic card found, but the current version work just fine. Anyway, I am stopping the SMBIOS and Device Properties patching for Other Oses, no quirk needed. 1 Link to comment Share on other sites More sharing options...
mhaeuser Posted December 28, 2019 Share Posted December 28, 2019 17 minutes ago, Slice said: I said "will be better". And it is wrong of me to ask for hints or references for a claim? Link to comment Share on other sites More sharing options...
texem Posted December 28, 2019 Share Posted December 28, 2019 1 hour ago, n.d.k said: Anyway, I am stopping the SMBIOS and Device Properties patching for Other Oses, no quirk needed. thank you, just recompiled - perfectly working Link to comment Share on other sites More sharing options...
STLVNUB Posted December 29, 2019 Share Posted December 29, 2019 Just as a matter of interest, how are you guys compiling this. I get errors using a customised builder using GCC5 and XCODE5 /Users/stlvnub/src/OpenCorePkg/UDK/OcSupportPkg/Library/OcGuardLib/NativeOverflow.c:29:3: error: expected declaration specifiers or '...' before 'sizeof' 29 | sizeof (INTN) == sizeof (INT64) || sizeof (INTN) == sizeof (INT32), | ^~~~~~ /Users/stlvnub/src/OpenCorePkg/UDK/OcSupportPkg/Library/OcGuardLib/NativeOverflow.c:30:3: error: expected declaration specifiers or '...' before string constant 30 | "INTN must be 32 or 64 Bits wide." | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /Users/stlvnub/src/OpenCorePkg/UDK/OcSupportPkg/Library/OcGuardLib/NativeOverflow.c:34:3: error: expected declaration specifiers or '...' before 'sizeof' 34 | sizeof (UINTN) == sizeof (UINT64) || sizeof (UINTN) == sizeof (UINT32), | ^~~~~~ /Users/stlvnub/src/OpenCorePkg/UDK/OcSupportPkg/Library/OcGuardLib/NativeOverflow.c:35:3: error: expected declaration specifiers or '...' before string constant 35 | "UINTN must be 32 or 64 Bits wide." | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ make: *** [/Users/stlvnub/src/OpenCorePkg/UDK/Build/OpenCorePkg/DEBUG_GCC5/X64/OcSupportPkg/Library/OcGuardLib/OcGuardLib/OUTPUT/NativeOverflow.obj] Error Link to comment Share on other sites More sharing options...
moozuki Posted December 29, 2019 Share Posted December 29, 2019 On 12/28/2019 at 9:13 AM, texem said: This answer is really very helpful. Thanks Are you talking about this fork or origin OC ? Official release OC, not this fork. Was just giving example of why this mod would be useful. Link to comment Share on other sites More sharing options...
n.d.k Posted December 29, 2019 Author Share Posted December 29, 2019 9 hours ago, STLVNUB said: Just as a matter of interest, how are you guys compiling this. I get errors using a customised builder using GCC5 and XCODE5 /Users/stlvnub/src/OpenCorePkg/UDK/OcSupportPkg/Library/OcGuardLib/NativeOverflow.c:29:3: error: expected declaration specifiers or '...' before 'sizeof' 29 | sizeof (INTN) == sizeof (INT64) || sizeof (INTN) == sizeof (INT32), | ^~~~~~ /Users/stlvnub/src/OpenCorePkg/UDK/OcSupportPkg/Library/OcGuardLib/NativeOverflow.c:30:3: error: expected declaration specifiers or '...' before string constant 30 | "INTN must be 32 or 64 Bits wide." | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /Users/stlvnub/src/OpenCorePkg/UDK/OcSupportPkg/Library/OcGuardLib/NativeOverflow.c:34:3: error: expected declaration specifiers or '...' before 'sizeof' 34 | sizeof (UINTN) == sizeof (UINT64) || sizeof (UINTN) == sizeof (UINT32), | ^~~~~~ /Users/stlvnub/src/OpenCorePkg/UDK/OcSupportPkg/Library/OcGuardLib/NativeOverflow.c:35:3: error: expected declaration specifiers or '...' before string constant 35 | "UINTN must be 32 or 64 Bits wide." | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ make: *** [/Users/stlvnub/src/OpenCorePkg/UDK/Build/OpenCorePkg/DEBUG_GCC5/X64/OcSupportPkg/Library/OcGuardLib/OcGuardLib/OUTPUT/NativeOverflow.obj] Error You need to link both OpenCorePkg and OcSupportPkg from this fork. 1 Link to comment Share on other sites More sharing options...
STLVNUB Posted December 30, 2019 Share Posted December 30, 2019 (edited) 11 hours ago, n.d.k said: You need to link both OpenCorePkg and OcSupportPkg from this fork. build.py... /Users/stlvnub/src/OpenCorePkg/UDK/OpenCorePkg/OpenCorePkg.dsc(61): error 000E: File/directory not found in workspace /Users/stlvnub/src/OpenCorePkg/UDK/OcSupportPkg/Library/OcAppleKeyMapLib/OcAppleKeyMapLib.inf I've changed the script to point to said PKG but still same error. AppleRamDiskLib/OcAppleRamDiskLib.c:17: /Users/stlvnub/src/OpenCorePkg/UDK/EfiPkg/Include/Protocol/AppleRamDisk.h:282:16: error: expected declaration specifiers or '...' before 'sizeof' 282 | STATIC_ASSERT (sizeof (APPLE_RAM_DISK_DP_VENDOR) == 24, "Invalid APPLE_RAM_DISK_DP_VENDOR size"); | ^~~~~~ /Users/stlvnub/src/OpenCorePkg/UDK/EfiPkg/Include/Protocol/AppleRamDisk.h:282:57: error: expected declaration specifiers or '...' before string constant 282 | STATIC_ASSERT (sizeof (APPLE_RAM_DISK_DP_VENDOR) == 24, "Invalid APPLE_RAM_DISK_DP_VENDOR size"); | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /Users/stlvnub/src/OpenCorePkg/UDK/EfiPkg/Include/Protocol/AppleRamDisk.h:283:16: error: expected declaration specifiers or '...' before 'sizeof' 283 | STATIC_ASSERT (sizeof (APPLE_RAM_DISK_DP) == 52, "Invalid APPLE_RAM_DISK_DP size"); | ^~~~~~ /Users/stlvnub/src/OpenCorePkg/UDK/EfiPkg/Include/Protocol/AppleRamDisk.h:283:50: error: expected declaration specifiers or '...' before string constant 283 | STATIC_ASSERT (sizeof (APPLE_RAM_DISK_DP) == 52, "Invalid APPLE_RAM_DISK_DP size"); | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /Users/stlvnub/src/OpenCorePkg/UDK/EfiPkg/Include/Protocol/AppleRamDisk.h:284:16: error: expected declaration specifiers or '...' before 'sizeof' 284 | STATIC_ASSERT (sizeof (APPLE_RAM_DISK_EXTENT) == 16, "Invalid APPLE_RAM_DISK_EXTENT size"); | ^~~~~~ /Users/stlvnub/src/OpenCorePkg/UDK/EfiPkg/Include/Protocol/AppleRamDisk.h:284:54: error: expected declaration specifiers or '...' before string constant 284 | STATIC_ASSERT (sizeof (APPLE_RAM_DISK_EXTENT) == 16, "Invalid APPLE_RAM_DISK_EXTENT size"); | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /Users/stlvnub/src/OpenCorePkg/UDK/EfiPkg/Include/Protocol/AppleRamDisk.h:285:16: error: expected declaration specifiers or '...' before 'sizeof' 285 | STATIC_ASSERT (sizeof (APPLE_RAM_DISK_EXTENT_TABLE) == 4096, "Invalid APPLE_RAM_DISK_EXTENT_TABLE size"); | ^~~~~~ /Users/stlvnub/src/OpenCorePkg/UDK/EfiPkg/Include/Protocol/AppleRamDisk.h:285:62: error: expected declaration specifiers or '...' before string constant 285 | STATIC_ASSERT (sizeof (APPLE_RAM_DISK_EXTENT_TABLE) == 4096, "Invalid APPLE_RAM_DISK_EXTENT_TABLE size"); | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /Users/stlvnub/src/OpenCorePkg/UDK/EfiPkg/Include/Protocol/AppleRamDisk.h:286:16: error: expected declaration specifiers or '...' before 'sizeof' 286 | STATIC_ASSERT (sizeof (APPLE_RAM_DISK_CONTEXT) == 8192, "Invalid APPLE_RAM_DISK_CONTEXT size"); | ^~~~~~ /Users/stlvnub/src/OpenCorePkg/UDK/EfiPkg/Include/Protocol/AppleRamDisk.h:286:57: error: expected declaration specifiers or '...' before string constant 286 | STATIC_ASSERT (sizeof (APPLE_RAM_DISK_CONTEXT) == 8192, "Invalid APPLE_RAM_DISK_CONTEXT size"); | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ make: *** [/Users/stlvnub/src/OpenCorePkg/UDK/Build/OpenCorePkg/DEBUG_GCC5/X64/OcSupportPkg/Library/OcAppleRamDiskLib/OcAppleRamDiskLib/OUTPUT/OcAppleRamDiskLib.obj] Error 1 build.py... : error 7000: Failed to execute command /Users/stlvnub/opt/local/cross/bin/x86_64-clover-linux-gnu-make tbuild [/Users/stlvnub/src/OpenCorePkg/UDK/Build/OpenCorePkg/DEBUG_GCC5/X64/OcSupportPkg/Library/OcAppleRamDiskLib/OcAppleRamDiskLib] build.py... : error F002: Failed to build module /Users/stlvnub/src/OpenCorePkg/UDK/OcSupportPkg/Library/OcAppleRamDiskLib/OcAppleRamDiskLib.inf [X64, GCC5, DEBUG] - Failed - Build end time: 16:43:56, Dec.30 2019 Build total time: 00:00:03 Edited December 30, 2019 by STLVNUB Link to comment Share on other sites More sharing options...
n.d.k Posted December 30, 2019 Author Share Posted December 30, 2019 (edited) 1 hour ago, STLVNUB said: build.py... /Users/stlvnub/src/OpenCorePkg/UDK/OpenCorePkg/OpenCorePkg.dsc(61): error 000E: File/directory not found in workspace /Users/stlvnub/src/OpenCorePkg/UDK/OcSupportPkg/Library/OcAppleKeyMapLib/OcAppleKeyMapLib.inf I've changed the script to point to said PKG but still same error. AppleRamDiskLib/OcAppleRamDiskLib.c:17: /Users/stlvnub/src/OpenCorePkg/UDK/EfiPkg/Include/Protocol/AppleRamDisk.h:282:16: error: expected declaration specifiers or '...' before 'sizeof' 282 | STATIC_ASSERT (sizeof (APPLE_RAM_DISK_DP_VENDOR) == 24, "Invalid APPLE_RAM_DISK_DP_VENDOR size"); | ^~~~~~ /Users/stlvnub/src/OpenCorePkg/UDK/EfiPkg/Include/Protocol/AppleRamDisk.h:282:57: error: expected declaration specifiers or '...' before string constant 282 | STATIC_ASSERT (sizeof (APPLE_RAM_DISK_DP_VENDOR) == 24, "Invalid APPLE_RAM_DISK_DP_VENDOR size"); | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /Users/stlvnub/src/OpenCorePkg/UDK/EfiPkg/Include/Protocol/AppleRamDisk.h:283:16: error: expected declaration specifiers or '...' before 'sizeof' 283 | STATIC_ASSERT (sizeof (APPLE_RAM_DISK_DP) == 52, "Invalid APPLE_RAM_DISK_DP size"); | ^~~~~~ /Users/stlvnub/src/OpenCorePkg/UDK/EfiPkg/Include/Protocol/AppleRamDisk.h:283:50: error: expected declaration specifiers or '...' before string constant 283 | STATIC_ASSERT (sizeof (APPLE_RAM_DISK_DP) == 52, "Invalid APPLE_RAM_DISK_DP size"); | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /Users/stlvnub/src/OpenCorePkg/UDK/EfiPkg/Include/Protocol/AppleRamDisk.h:284:16: error: expected declaration specifiers or '...' before 'sizeof' 284 | STATIC_ASSERT (sizeof (APPLE_RAM_DISK_EXTENT) == 16, "Invalid APPLE_RAM_DISK_EXTENT size"); | ^~~~~~ /Users/stlvnub/src/OpenCorePkg/UDK/EfiPkg/Include/Protocol/AppleRamDisk.h:284:54: error: expected declaration specifiers or '...' before string constant 284 | STATIC_ASSERT (sizeof (APPLE_RAM_DISK_EXTENT) == 16, "Invalid APPLE_RAM_DISK_EXTENT size"); | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /Users/stlvnub/src/OpenCorePkg/UDK/EfiPkg/Include/Protocol/AppleRamDisk.h:285:16: error: expected declaration specifiers or '...' before 'sizeof' 285 | STATIC_ASSERT (sizeof (APPLE_RAM_DISK_EXTENT_TABLE) == 4096, "Invalid APPLE_RAM_DISK_EXTENT_TABLE size"); | ^~~~~~ /Users/stlvnub/src/OpenCorePkg/UDK/EfiPkg/Include/Protocol/AppleRamDisk.h:285:62: error: expected declaration specifiers or '...' before string constant 285 | STATIC_ASSERT (sizeof (APPLE_RAM_DISK_EXTENT_TABLE) == 4096, "Invalid APPLE_RAM_DISK_EXTENT_TABLE size"); | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /Users/stlvnub/src/OpenCorePkg/UDK/EfiPkg/Include/Protocol/AppleRamDisk.h:286:16: error: expected declaration specifiers or '...' before 'sizeof' 286 | STATIC_ASSERT (sizeof (APPLE_RAM_DISK_CONTEXT) == 8192, "Invalid APPLE_RAM_DISK_CONTEXT size"); | ^~~~~~ /Users/stlvnub/src/OpenCorePkg/UDK/EfiPkg/Include/Protocol/AppleRamDisk.h:286:57: error: expected declaration specifiers or '...' before string constant 286 | STATIC_ASSERT (sizeof (APPLE_RAM_DISK_CONTEXT) == 8192, "Invalid APPLE_RAM_DISK_CONTEXT size"); | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ make: *** [/Users/stlvnub/src/OpenCorePkg/UDK/Build/OpenCorePkg/DEBUG_GCC5/X64/OcSupportPkg/Library/OcAppleRamDiskLib/OcAppleRamDiskLib/OUTPUT/OcAppleRamDiskLib.obj] Error 1 build.py... : error 7000: Failed to execute command /Users/stlvnub/opt/local/cross/bin/x86_64-clover-linux-gnu-make tbuild [/Users/stlvnub/src/OpenCorePkg/UDK/Build/OpenCorePkg/DEBUG_GCC5/X64/OcSupportPkg/Library/OcAppleRamDiskLib/OcAppleRamDiskLib] build.py... : error F002: Failed to build module /Users/stlvnub/src/OpenCorePkg/UDK/OcSupportPkg/Library/OcAppleRamDiskLib/OcAppleRamDiskLib.inf [X64, GCC5, DEBUG] - Failed - Build end time: 16:43:56, Dec.30 2019 Build total time: 00:00:03 Please read post #1 how to build, git clone the fork and cd into the folder and run ./ndk-macbuild.tool From the look of those errors, you may have used out dated UDK version. Edited December 30, 2019 by n.d.k 2 Link to comment Share on other sites More sharing options...
HmO Posted December 30, 2019 Share Posted December 30, 2019 Build from latest source without any problem just run into terminal ndk-macbuild.tool 1 Link to comment Share on other sites More sharing options...
Mike Ranger Posted December 30, 2019 Share Posted December 30, 2019 I think those are very useful features..... in my opinion it should be merged what you do. Thanks for your effort and contributions. I still have to sort out some stuff with my install but that will eventually also work. Link to comment Share on other sites More sharing options...
Recommended Posts