mirror of
https://github.com/dortania/OpenCore-Legacy-Patcher.git
synced 2026-04-11 16:27:19 +10:00
build.py: Add USB1.1 injection
This commit is contained in:
@@ -22,6 +22,7 @@
|
||||
- Resolve Ethernet support on MacPro3,1-5,1
|
||||
- Fix VMM patch set
|
||||
- Allow dyld shared cache swapping on pre-Haswell
|
||||
- Add USB1.1 injection for pre-Ivy bridge units
|
||||
|
||||
## 0.4.6
|
||||
- Fix Bluetooth support in 12.4 Release
|
||||
|
||||
@@ -1365,6 +1365,78 @@
|
||||
<key>PlistPath</key>
|
||||
<string>Contents/Info.plist</string>
|
||||
</dict>
|
||||
<dict>
|
||||
<key>Arch</key>
|
||||
<string>x86_64</string>
|
||||
<key>BundlePath</key>
|
||||
<string>USB1.1-Injector.kext/Contents/PlugIns/AppleUSBOHCI.kext</string>
|
||||
<key>Comment</key>
|
||||
<string>USB1.1 - AppleUSBOHCI</string>
|
||||
<key>Enabled</key>
|
||||
<false/>
|
||||
<key>ExecutablePath</key>
|
||||
<string>Contents/MacOS/AppleUSBOHCI</string>
|
||||
<key>MaxKernel</key>
|
||||
<string></string>
|
||||
<key>MinKernel</key>
|
||||
<string>22.0.0</string>
|
||||
<key>PlistPath</key>
|
||||
<string>Contents/Info.plist</string>
|
||||
</dict>
|
||||
<dict>
|
||||
<key>Arch</key>
|
||||
<string>x86_64</string>
|
||||
<key>BundlePath</key>
|
||||
<string>USB1.1-Injector.kext/Contents/PlugIns/AppleUSBOHCIPCI.kext</string>
|
||||
<key>Comment</key>
|
||||
<string>USB1.1 - AppleUSBOHCIPCI</string>
|
||||
<key>Enabled</key>
|
||||
<false/>
|
||||
<key>ExecutablePath</key>
|
||||
<string>Contents/MacOS/AppleUSBOHCIPCI</string>
|
||||
<key>MaxKernel</key>
|
||||
<string></string>
|
||||
<key>MinKernel</key>
|
||||
<string>22.0.0</string>
|
||||
<key>PlistPath</key>
|
||||
<string>Contents/Info.plist</string>
|
||||
</dict>
|
||||
<dict>
|
||||
<key>Arch</key>
|
||||
<string>x86_64</string>
|
||||
<key>BundlePath</key>
|
||||
<string>USB1.1-Injector.kext/Contents/PlugIns/AppleUSBUHCI.kext</string>
|
||||
<key>Comment</key>
|
||||
<string>USB1.1 - AppleUSBUHCI</string>
|
||||
<key>Enabled</key>
|
||||
<false/>
|
||||
<key>ExecutablePath</key>
|
||||
<string>Contents/MacOS/AppleUSBUHCI</string>
|
||||
<key>MaxKernel</key>
|
||||
<string></string>
|
||||
<key>MinKernel</key>
|
||||
<string>22.0.0</string>
|
||||
<key>PlistPath</key>
|
||||
<string>Contents/Info.plist</string>
|
||||
</dict>
|
||||
<dict>
|
||||
<key>Arch</key>
|
||||
<string>x86_64</string>
|
||||
<key>BundlePath</key>
|
||||
<string>USB1.1-Injector.kext/Contents/PlugIns/AppleUSBUHCIPCI.kext</string>
|
||||
<key>Comment</key>
|
||||
<string>USB1.1 - AppleUSBUHCIPCI</string>
|
||||
<key>Enabled</key>
|
||||
<false/>
|
||||
<key>ExecutablePath</key>
|
||||
<string>Contents/MacOS/AppleUSBUHCIPCI</string>
|
||||
<key>MaxKernel</key>
|
||||
<string></string>
|
||||
<key>MinKernel</key>
|
||||
<string>22.0.0</string>
|
||||
<key>PlistPath</key>
|
||||
<string>Contents/Info.plist</string>
|
||||
</dict>
|
||||
</array>
|
||||
<key>Block</key>
|
||||
<array/>
|
||||
|
||||
BIN
payloads/Kexts/USB/USB1.1-Injector-v1.0.0.zip
Normal file
BIN
payloads/Kexts/USB/USB1.1-Injector-v1.0.0.zip
Normal file
Binary file not shown.
@@ -886,6 +886,26 @@ class BuildOpenCore:
|
||||
self.get_efi_binary_by_path("XhciDxe.efi", "UEFI", "Drivers")["Enabled"] = True
|
||||
self.get_efi_binary_by_path("UsbBusDxe.efi", "UEFI", "Drivers")["Enabled"] = True
|
||||
|
||||
# Add UHCI/OHCI drivers
|
||||
if not self.constants.custom_model:
|
||||
if self.constants.computer.usb_controllers:
|
||||
for controller in self.constants.computer.usb_controllers:
|
||||
if isinstance(controller, device_probe.UHCIController) or isinstance(controller, device_probe.OHCIController):
|
||||
print("- Adding UHCI/OHCI USB support")
|
||||
shutil.copy(self.constants.apple_usb_11_injector_path, self.constants.kexts_path)
|
||||
self.get_kext_by_bundle_path("USB1.1-Injector.kext/Contents/PlugIns/AppleUSBOHCI.kext")["Enabled"] = True
|
||||
self.get_kext_by_bundle_path("USB1.1-Injector.kext/Contents/PlugIns/AppleUSBOHCIPCI.kext")["Enabled"] = True
|
||||
self.get_kext_by_bundle_path("USB1.1-Injector.kext/Contents/PlugIns/AppleUSBUHCI.kext")["Enabled"] = True
|
||||
self.get_kext_by_bundle_path("USB1.1-Injector.kext/Contents/PlugIns/AppleUSBUHCIPCI.kext")["Enabled"] = True
|
||||
else:
|
||||
if smbios_data.smbios_dictionary[self.model]["CPU Generation"] <= cpu_data.cpu_data.sandy_bridge.value:
|
||||
print("- Adding UHCI/OHCI USB support")
|
||||
shutil.copy(self.constants.apple_usb_11_injector_path, self.constants.kexts_path)
|
||||
self.get_kext_by_bundle_path("USB1.1-Injector.kext/Contents/PlugIns/AppleUSBOHCI.kext")["Enabled"] = True
|
||||
self.get_kext_by_bundle_path("USB1.1-Injector.kext/Contents/PlugIns/AppleUSBOHCIPCI.kext")["Enabled"] = True
|
||||
self.get_kext_by_bundle_path("USB1.1-Injector.kext/Contents/PlugIns/AppleUSBUHCI.kext")["Enabled"] = True
|
||||
self.get_kext_by_bundle_path("USB1.1-Injector.kext/Contents/PlugIns/AppleUSBUHCIPCI.kext")["Enabled"] = True
|
||||
|
||||
# ThirdPartDrives Check
|
||||
if self.constants.allow_3rd_party_drives is True:
|
||||
for drive in ["SATA 2.5", "SATA 3.5", "mSATA"]:
|
||||
|
||||
@@ -60,6 +60,7 @@ class Constants:
|
||||
self.topcase_version = "1.0.0" # AppleUSBTopCase
|
||||
self.intel_82574l_version = "1.0.0" # Intel82574L
|
||||
self.intel_8254x_version = "1.0.0" # AppleIntel8254XEthernet
|
||||
self.apple_usb_11_injector = "1.0.0" # AppleUSBUHCI/OHCI
|
||||
|
||||
## Apple - Dortania Modified
|
||||
self.bcm570_version = "1.0.2" # CatalinaBCM5701Ethernet
|
||||
@@ -313,6 +314,10 @@ class Constants:
|
||||
def intel_8254x_path(self):
|
||||
return self.payload_kexts_path / Path(f"Ethernet/AppleIntel8254XEthernet-v{self.intel_8254x_version}.zip")
|
||||
|
||||
@property
|
||||
def apple_usb_11_injector_path(self):
|
||||
return self.payload_kexts_path / Path(f"USB/USB1.1-Injector-v{self.apple_usb_11_injector}.zip")
|
||||
|
||||
@property
|
||||
def mce_path(self):
|
||||
return self.payload_kexts_path / Path(f"Misc/AppleMCEReporterDisabler-v{self.mce_version}.zip")
|
||||
|
||||
Reference in New Issue
Block a user