mirror of
https://github.com/dortania/OpenCore-Legacy-Patcher.git
synced 2026-04-24 03:50:14 +10:00
Seperate GUI
This commit is contained in:
@@ -84,6 +84,7 @@ while MainMenu:
|
|||||||
print (" %s" % Versions.current_path)
|
print (" %s" % Versions.current_path)
|
||||||
print("")
|
print("")
|
||||||
BuildOpenCore.BuildEFI()
|
BuildOpenCore.BuildEFI()
|
||||||
|
BuildOpenCore.BuildGUI()
|
||||||
BuildOpenCore.BuildSMBIOS()
|
BuildOpenCore.BuildSMBIOS()
|
||||||
BuildOpenCore.SavePlist()
|
BuildOpenCore.SavePlist()
|
||||||
BuildOpenCore.CleanBuildFolder()
|
BuildOpenCore.CleanBuildFolder()
|
||||||
|
|||||||
@@ -88,8 +88,16 @@ Xserve3,1
|
|||||||
|
|
||||||
## How to run
|
## How to run
|
||||||
|
|
||||||
|
Prerequists:
|
||||||
|
|
||||||
|
* Supported Mac(see above)
|
||||||
|
* macOS Installer installed to USB
|
||||||
|
* Blank USB drives formatted as GUID Partition Table are also supported
|
||||||
|
|
||||||
1. [Download the release](https://github.com/dortania/Opencore-Legacy-Patcher/releases)
|
1. [Download the release](https://github.com/dortania/Opencore-Legacy-Patcher/releases)
|
||||||
2. Run the `OpenCore-Patcher.command` file
|
2. Run the `OpenCore-Patcher.command` file
|
||||||
3. Once opened, select option 1 and build your EFI
|
3. Once opened, select option 1 and build your EFI
|
||||||
* if poatching for a different patching, selectect option 3 first
|
* if poatching for a different patching, selectect option 3 first
|
||||||
4. Once finished, run option 2 a the main menu and install onto your desired drive
|
4. Once finished, run option 2 a the main menu and install onto your desired drive
|
||||||
|
|
||||||
|
Once you're done making your OpenCore installer, you can simply reboot holding the Option key. In the picker, you should see a new EFI Boot Option. Boot it and from there you'll be in the OpenCore picker.
|
||||||
@@ -171,6 +171,15 @@ def BuildEFI():
|
|||||||
map_name
|
map_name
|
||||||
)
|
)
|
||||||
|
|
||||||
|
def BuildGUI():
|
||||||
|
print("- Adding OpenCanopy GUI")
|
||||||
|
rmtree(Versions.gui_path_build)
|
||||||
|
copy(Versions.gui_path, Versions.plist_path_build)
|
||||||
|
Versions.plist_data = Versions.plist_data.replace(
|
||||||
|
"#OpenCanopy.efi",
|
||||||
|
"OpenCanopy.efi"
|
||||||
|
)
|
||||||
|
|
||||||
def BuildSMBIOS():
|
def BuildSMBIOS():
|
||||||
# Set new SMBIOS
|
# Set new SMBIOS
|
||||||
new_model = current_model
|
new_model = current_model
|
||||||
@@ -251,6 +260,17 @@ def CleanBuildFolder():
|
|||||||
zip_ref.close()
|
zip_ref.close()
|
||||||
os.remove(file_name)
|
os.remove(file_name)
|
||||||
# Clean up Python's unzip
|
# Clean up Python's unzip
|
||||||
|
if os.path.exists("__MACOSX"):
|
||||||
|
rmtree("__MACOSX")
|
||||||
|
os.chdir(Versions.plist_path_build)
|
||||||
|
os.chdir(Versions.plist_path_build)
|
||||||
|
for item in os.listdir(Versions.plist_path_build):
|
||||||
|
if item.endswith(".zip"):
|
||||||
|
file_name = os.path.abspath(item)
|
||||||
|
zip_ref = zipfile.ZipFile(file_name)
|
||||||
|
zip_ref.extractall(Versions.plist_path_build)
|
||||||
|
zip_ref.close()
|
||||||
|
os.remove(file_name)
|
||||||
if os.path.exists("__MACOSX"):
|
if os.path.exists("__MACOSX"):
|
||||||
rmtree("__MACOSX")
|
rmtree("__MACOSX")
|
||||||
os.chdir(Versions.build_path)
|
os.chdir(Versions.build_path)
|
||||||
|
|||||||
@@ -326,6 +326,22 @@ NVMePatch = [
|
|||||||
"Xserve3,1"
|
"Xserve3,1"
|
||||||
]
|
]
|
||||||
|
|
||||||
|
SidecarPatch = [
|
||||||
|
"MacBookAir5,1",
|
||||||
|
"MacBookAir5,2",
|
||||||
|
"MacBookPro9,1",
|
||||||
|
"MacBookPro9,2",
|
||||||
|
"MacBookPro10,1",
|
||||||
|
"MacBookPro10,2",
|
||||||
|
"Macmini6,1",
|
||||||
|
"Macmini6,2",
|
||||||
|
"iMac13,1",
|
||||||
|
"iMac13,2",
|
||||||
|
"iMac14,1",
|
||||||
|
"iMac14,2",
|
||||||
|
"iMac14,3"
|
||||||
|
]
|
||||||
|
|
||||||
# 11" Air
|
# 11" Air
|
||||||
MacBookAir61 = [
|
MacBookAir61 = [
|
||||||
"MacBookAir3,1",
|
"MacBookAir3,1",
|
||||||
|
|||||||
@@ -62,10 +62,11 @@ drivers_path_build = os.path.join(current_path, "Build-Folder/" "OpenCore-v%s/EF
|
|||||||
kext_path_build = os.path.join(current_path, "Build-Folder/" "OpenCore-v%s/EFI/OC/Kexts" % opencore_version)
|
kext_path_build = os.path.join(current_path, "Build-Folder/" "OpenCore-v%s/EFI/OC/Kexts" % opencore_version)
|
||||||
opencore_path_done = os.path.join(current_path, "Build-Folder/" "OpenCore-v%s" % opencore_version)
|
opencore_path_done = os.path.join(current_path, "Build-Folder/" "OpenCore-v%s" % opencore_version)
|
||||||
build_path = os.path.join(current_path, r'Build-Folder/')
|
build_path = os.path.join(current_path, r'Build-Folder/')
|
||||||
|
gui_path_build = os.path.join(current_path, "Build-Folder/" "OpenCore-v%s/EFI/OC/Resources" % opencore_version)
|
||||||
|
|
||||||
# Tools
|
# Tools
|
||||||
macserial_path = os.path.join(current_path, "payloads/" "Tools")
|
macserial_path = os.path.join(current_path, "payloads/" "Tools")
|
||||||
|
|
||||||
# Icons
|
# Icons
|
||||||
|
|
||||||
icon_path = os.path.join(current_path, "payloads/Icon/" ".VolumeIcon.icns")
|
icon_path = os.path.join(current_path, "payloads/Icon/" ".VolumeIcon.icns")
|
||||||
|
gui_path = os.path.join(current_path, "payloads/Icon/" "Resources.zip")
|
||||||
@@ -776,7 +776,7 @@
|
|||||||
<key>Drivers</key>
|
<key>Drivers</key>
|
||||||
<array>
|
<array>
|
||||||
<string>#NvmExpressDxe.efi</string>
|
<string>#NvmExpressDxe.efi</string>
|
||||||
<string>OpenCanopy.efi</string>
|
<string>#OpenCanopy.efi</string>
|
||||||
<string>OpenRuntime.efi</string>
|
<string>OpenRuntime.efi</string>
|
||||||
</array>
|
</array>
|
||||||
<key>Input</key>
|
<key>Input</key>
|
||||||
|
|||||||
BIN
payloads/Icon/Resources.zip
Normal file
BIN
payloads/Icon/Resources.zip
Normal file
Binary file not shown.
Binary file not shown.
Reference in New Issue
Block a user