mirror of
https://github.com/dortania/OpenCore-Legacy-Patcher.git
synced 2026-06-20 14:10:51 +10:00
Import dosdude1 patches
This commit is contained in:
@@ -304,6 +304,8 @@ class Constants:
|
|||||||
def legacy_intel_gen2_path(self): return self.legacy_graphics / Path("Intel-Gen6-SandyBridge")
|
def legacy_intel_gen2_path(self): return self.legacy_graphics / Path("Intel-Gen6-SandyBridge")
|
||||||
@property
|
@property
|
||||||
def legacy_intel_gen3_path(self): return self.legacy_graphics / Path("Intel-Gen7-IvyBridge")
|
def legacy_intel_gen3_path(self): return self.legacy_graphics / Path("Intel-Gen7-IvyBridge")
|
||||||
|
@property
|
||||||
|
def legacy_general_path(self): return self.legacy_graphics / Path("General-Patches")
|
||||||
|
|
||||||
@property
|
@property
|
||||||
def legacy_brightness(self): return self.payload_apple_kexts_path / Path("Brightness-Control")
|
def legacy_brightness(self): return self.payload_apple_kexts_path / Path("Brightness-Control")
|
||||||
|
|||||||
+10
-4
@@ -962,8 +962,6 @@ AddAMDAccel11 = [
|
|||||||
"ATIRadeonX2000GA.plugin",
|
"ATIRadeonX2000GA.plugin",
|
||||||
"ATIRadeonX2000GLDriver.bundle",
|
"ATIRadeonX2000GLDriver.bundle",
|
||||||
"ATIRadeonX2000VADriver.bundle",
|
"ATIRadeonX2000VADriver.bundle",
|
||||||
"IOAcceleratorFamily2.kext",
|
|
||||||
"IOSurface.kext",
|
|
||||||
]
|
]
|
||||||
|
|
||||||
AddIntelGen1Accel = [
|
AddIntelGen1Accel = [
|
||||||
@@ -972,7 +970,6 @@ AddIntelGen1Accel = [
|
|||||||
"AppleIntelHDGraphicsGA.plugin",
|
"AppleIntelHDGraphicsGA.plugin",
|
||||||
"AppleIntelHDGraphicsGLDriver.bundle",
|
"AppleIntelHDGraphicsGLDriver.bundle",
|
||||||
"AppleIntelHDGraphicsVADriver.bundle",
|
"AppleIntelHDGraphicsVADriver.bundle",
|
||||||
"IOSurface.kext",
|
|
||||||
]
|
]
|
||||||
|
|
||||||
AddIntelGen2Accel = [
|
AddIntelGen2Accel = [
|
||||||
@@ -982,7 +979,6 @@ AddIntelGen2Accel = [
|
|||||||
"AppleIntelHD3000GraphicsVADriver.bundle",
|
"AppleIntelHD3000GraphicsVADriver.bundle",
|
||||||
"AppleIntelSNBGraphicsFB.kext",
|
"AppleIntelSNBGraphicsFB.kext",
|
||||||
"AppleIntelSNBVA.bundle",
|
"AppleIntelSNBVA.bundle",
|
||||||
"IOSurface.kext",
|
|
||||||
]
|
]
|
||||||
|
|
||||||
AddIntelGen3Accel = [
|
AddIntelGen3Accel = [
|
||||||
@@ -993,6 +989,16 @@ AddIntelGen3Accel = [
|
|||||||
"AppleIntelHD4000GraphicsVADriver.bundle",
|
"AppleIntelHD4000GraphicsVADriver.bundle",
|
||||||
]
|
]
|
||||||
|
|
||||||
|
AddGeneralAccel = [
|
||||||
|
"AppleGraphicsControl.kext",
|
||||||
|
"AppleGraphicsPowerManagement.kext",
|
||||||
|
"AppleMCCSControl.kext",
|
||||||
|
"IOGraphicsFamily.kext",
|
||||||
|
"IONDRVSupport.kext",
|
||||||
|
"IOAcceleratorFamily2.kext",
|
||||||
|
"IOSurface.kext"
|
||||||
|
]
|
||||||
|
|
||||||
DeleteBrightness = [
|
DeleteBrightness = [
|
||||||
"AppleGraphicsControl.kext/Contents/PlugIns/AGDCBacklightControl.kext"
|
"AppleGraphicsControl.kext/Contents/PlugIns/AGDCBacklightControl.kext"
|
||||||
]
|
]
|
||||||
|
|||||||
@@ -130,6 +130,7 @@ class PatchSysVolume:
|
|||||||
if dgpu_device in PCIIDArray.nvidia_ids().tesla_ids or dgpu_device in PCIIDArray.nvidia_ids().fermi_ids:
|
if dgpu_device in PCIIDArray.nvidia_ids().tesla_ids or dgpu_device in PCIIDArray.nvidia_ids().fermi_ids:
|
||||||
print("- Merging legacy Nvidia Tesla and Fermi Kexts and Bundles")
|
print("- Merging legacy Nvidia Tesla and Fermi Kexts and Bundles")
|
||||||
self.delete_old_binaries(ModelArray.DeleteNvidiaAccel11)
|
self.delete_old_binaries(ModelArray.DeleteNvidiaAccel11)
|
||||||
|
self.add_new_binaries(ModelArray.AddGeneralAccel, self.constants.legacy_general_path)
|
||||||
self.add_new_binaries(ModelArray.AddNvidiaAccel11, self.constants.legacy_nvidia_path)
|
self.add_new_binaries(ModelArray.AddNvidiaAccel11, self.constants.legacy_nvidia_path)
|
||||||
# TODO: Enable below code if macOS 12 drops support
|
# TODO: Enable below code if macOS 12 drops support
|
||||||
#elif dgpu_device in PCIIDArray.nvidia_ids().kepler_ids and self.constants.detected_os > self.constants.big_sur:
|
#elif dgpu_device in PCIIDArray.nvidia_ids().kepler_ids and self.constants.detected_os > self.constants.big_sur:
|
||||||
@@ -139,6 +140,7 @@ class PatchSysVolume:
|
|||||||
if dgpu_device in PCIIDArray.amd_ids().terascale_1_ids or dgpu_device in PCIIDArray.amd_ids().terascale_2_ids:
|
if dgpu_device in PCIIDArray.amd_ids().terascale_1_ids or dgpu_device in PCIIDArray.amd_ids().terascale_2_ids:
|
||||||
print("- Merging legacy AMD Kexts and Bundles")
|
print("- Merging legacy AMD Kexts and Bundles")
|
||||||
self.delete_old_binaries(ModelArray.DeleteAMDAccel11)
|
self.delete_old_binaries(ModelArray.DeleteAMDAccel11)
|
||||||
|
self.add_new_binaries(ModelArray.AddGeneralAccel, self.constants.legacy_general_path)
|
||||||
self.add_new_binaries(ModelArray.AddAMDAccel11, self.constants.legacy_amd_path)
|
self.add_new_binaries(ModelArray.AddAMDAccel11, self.constants.legacy_amd_path)
|
||||||
if igpu_vendor:
|
if igpu_vendor:
|
||||||
print(f"- Found IGPU: {igpu_vendor}:{igpu_device}")
|
print(f"- Found IGPU: {igpu_vendor}:{igpu_device}")
|
||||||
@@ -146,15 +148,13 @@ class PatchSysVolume:
|
|||||||
if igpu_device in PCIIDArray.intel_ids().iron_ids:
|
if igpu_device in PCIIDArray.intel_ids().iron_ids:
|
||||||
print("- Merging legacy Intel 1st Gen Kexts and Bundles")
|
print("- Merging legacy Intel 1st Gen Kexts and Bundles")
|
||||||
self.delete_old_binaries(ModelArray.DeleteNvidiaAccel11)
|
self.delete_old_binaries(ModelArray.DeleteNvidiaAccel11)
|
||||||
|
self.add_new_binaries(ModelArray.AddGeneralAccel, self.constants.legacy_general_path)
|
||||||
self.add_new_binaries(ModelArray.AddIntelGen1Accel, self.constants.legacy_intel_gen1_path)
|
self.add_new_binaries(ModelArray.AddIntelGen1Accel, self.constants.legacy_intel_gen1_path)
|
||||||
elif igpu_device in PCIIDArray.intel_ids().sandy_ids:
|
elif igpu_device in PCIIDArray.intel_ids().sandy_ids:
|
||||||
print("- Merging legacy Intel 2nd Gen Kexts and Bundles")
|
print("- Merging legacy Intel 2nd Gen Kexts and Bundles")
|
||||||
self.delete_old_binaries(ModelArray.DeleteNvidiaAccel11)
|
self.delete_old_binaries(ModelArray.DeleteNvidiaAccel11)
|
||||||
|
self.add_new_binaries(ModelArray.AddGeneralAccel, self.constants.legacy_general_path)
|
||||||
self.add_new_binaries(ModelArray.AddIntelGen2Accel, self.constants.legacy_intel_gen2_path)
|
self.add_new_binaries(ModelArray.AddIntelGen2Accel, self.constants.legacy_intel_gen2_path)
|
||||||
#if self.model in ModelArray.LegacyGPUAMDIntelGen2:
|
|
||||||
# Swap custom AppleIntelSNBGraphicsFB-AMD.kext, required to fix linking
|
|
||||||
# subprocess.run(f"sudo rm -R {self.mount_extensions}/AppleIntelSNBGraphicsFB.kext".split(), stdout=subprocess.PIPE).stdout.decode().strip().encode()
|
|
||||||
# subprocess.run(f"sudo cp -R {self.constants.legacy_amd_path}/AMD-Link/AppleIntelSNBGraphicsFB.kext {self.mount_extensions}".split(), stdout=subprocess.PIPE).stdout.decode().strip().encode()
|
|
||||||
|
|
||||||
# TODO: Enable below code if macOS 12 drops support
|
# TODO: Enable below code if macOS 12 drops support
|
||||||
#elif igpu_device in PCIIDArray.intel_ids().ivy_ids:
|
#elif igpu_device in PCIIDArray.intel_ids().ivy_ids:
|
||||||
@@ -165,6 +165,7 @@ class PatchSysVolume:
|
|||||||
# Avoid patching twice, as Nvidia iGPUs will only have Nvidia dGPUs
|
# Avoid patching twice, as Nvidia iGPUs will only have Nvidia dGPUs
|
||||||
print("- Merging legacy Nvidia Kexts and Bundles")
|
print("- Merging legacy Nvidia Kexts and Bundles")
|
||||||
self.delete_old_binaries(ModelArray.DeleteNvidiaAccel11)
|
self.delete_old_binaries(ModelArray.DeleteNvidiaAccel11)
|
||||||
|
self.add_new_binaries(ModelArray.AddGeneralAccel, self.constants.legacy_general_path)
|
||||||
self.add_new_binaries(ModelArray.AddNvidiaAccel11, self.constants.legacy_nvidia_path)
|
self.add_new_binaries(ModelArray.AddNvidiaAccel11, self.constants.legacy_nvidia_path)
|
||||||
|
|
||||||
# Frameworks
|
# Frameworks
|
||||||
|
|||||||
Reference in New Issue
Block a user