mirror of
https://github.com/dortania/OpenCore-Legacy-Patcher.git
synced 2026-06-19 13:50:00 +10:00
Fix OpenCanopy and enhance build detection
This commit is contained in:
@@ -1,6 +1,9 @@
|
|||||||
# OpenCore Legacy Patcher changelog
|
# OpenCore Legacy Patcher changelog
|
||||||
|
|
||||||
## 0.0.21
|
## 0.0.21
|
||||||
|
- Fix botched images in OpenCanopy
|
||||||
|
- Add support for 3rd party OpenCore usage detection during building
|
||||||
|
- Mainly for users transtioning from Ausdauersportler's OpenCore configuration
|
||||||
|
|
||||||
## 0.0.20
|
## 0.0.20
|
||||||
- Fix CPU Calculation on early MCP79 chipsets (ie. iMac9,1, MacBook5,x)
|
- Fix CPU Calculation on early MCP79 chipsets (ie. iMac9,1, MacBook5,x)
|
||||||
|
|||||||
@@ -26,6 +26,20 @@ class OpenCoreLegacyPatcher():
|
|||||||
if self.current_model in ModelArray.NoAPFSsupport:
|
if self.current_model in ModelArray.NoAPFSsupport:
|
||||||
self.constants.serial_settings = "Moderate"
|
self.constants.serial_settings = "Moderate"
|
||||||
|
|
||||||
|
# Logic for when user runs custom OpenCore build and do not expose it
|
||||||
|
# Note: This logic currently only applies for iMacPro1,1 users, see below threads on the culprits:
|
||||||
|
# - https://forums.macrumors.com/threads/2011-imac-graphics-card-upgrade.1596614/post-17425857
|
||||||
|
# - https://forums.macrumors.com/threads/opencore-on-the-mac-pro.2207814/
|
||||||
|
# PLEASE FOR THE LOVE OF GOD JUST SET ExposeSensitiveData CORRECTLY!!!
|
||||||
|
if self.current_model == "iMacPro1,1":
|
||||||
|
serial: str = subprocess.run("system_profiler SPHardwareDataType | grep Serial".split(), stdout=subprocess.PIPE, stderr=subprocess.STDOUT).stdout.decode()
|
||||||
|
serial = [line.strip().split("Number (system): ", 1)[1] for line in serial.split("\n") if line.strip().startswith("Serial")][0]
|
||||||
|
true_model = subprocess.run([str(self.constants.macserial_path), "--info", str(serial)], stdout=subprocess.PIPE, stderr=subprocess.STDOUT)
|
||||||
|
true_model = [i.partition(" - ")[2] for i in true_model.stdout.decode().split("\n") if "Model: " in i][0]
|
||||||
|
print(f"True Model: {true_model}")
|
||||||
|
if not true_model.startswith("Unknown"):
|
||||||
|
self.current_model = true_model
|
||||||
|
|
||||||
def build_opencore(self):
|
def build_opencore(self):
|
||||||
build.BuildOpenCore(self.constants.custom_model or self.current_model, self.constants).build_opencore()
|
build.BuildOpenCore(self.constants.custom_model or self.current_model, self.constants).build_opencore()
|
||||||
|
|
||||||
|
|||||||
Binary file not shown.
Reference in New Issue
Block a user