Sync changelog

This commit is contained in:
Mykola Grymalyuk
2021-04-24 10:35:22 -06:00
parent e86b48e0fc
commit a5998cb226
5 changed files with 24 additions and 11 deletions

View File

@@ -16,6 +16,7 @@
- Fix TeraScale 1 GPU detection - Fix TeraScale 1 GPU detection
- Enable Graphics Acceleration on legacy GPUs by default - Enable Graphics Acceleration on legacy GPUs by default
- Automatically disable AMD TeraScale 2 GPUs in MacBook Pros - Automatically disable AMD TeraScale 2 GPUs in MacBook Pros
- Fix incorrectly disabling SIP/SMB on Metal GPUs
## 0.1.0 ## 0.1.0
- Fix crash on iMacs with Metal GPUs - Fix crash on iMacs with Metal GPUs

View File

@@ -3,6 +3,8 @@
from __future__ import print_function from __future__ import print_function
import binascii
import plistlib
import subprocess import subprocess
import sys import sys
import time import time
@@ -28,8 +30,18 @@ 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"
if self.current_model in ModelArray.LegacyGPU: if self.current_model in ModelArray.LegacyGPU:
Build.BuildOpenCore(self.constants.custom_model or self.current_model, self.constants).check_pciid(False) try:
if not (self.constants.dgpu_vendor == self.constants.pci_amd_ati and self.constants.dgpu_device in ModelArray.AMDMXMGPUs) or not (self.constants.dgpu_vendor == self.constants.pci_nvidia and self.constants.dgpu_device in ModelArray.NVIDIAMXMGPUs): dgpu_devices = plistlib.loads(subprocess.run("ioreg -r -n GFX0 -a".split(), stdout=subprocess.PIPE).stdout.decode().strip().encode())
dgpu_vendor = self.hexswap(binascii.hexlify(dgpu_devices[0]["vendor-id"]).decode()[:4])
dgpu_device = self.hexswap(binascii.hexlify(dgpu_devices[0]["device-id"]).decode()[:4])
except ValueError:
dgpu_vendor = ""
dgpu_device = ""
if (dgpu_vendor == self.constants.pci_amd_ati and dgpu_device in ModelArray.AMDMXMGPUs) or (dgpu_vendor == self.constants.pci_nvidia and dgpu_device in ModelArray.NVIDIAMXMGPUs):
self.constants.sip_status = True
self.constants.secure_status = True
else:
self.constants.sip_status = False self.constants.sip_status = False
self.constants.secure_status = False self.constants.secure_status = False
@@ -68,7 +80,6 @@ class OpenCoreLegacyPatcher():
# SysPatch args # SysPatch args
parser.add_argument('--patch_sys_vol', help='Patches root volume', action='store_true', required=False) parser.add_argument('--patch_sys_vol', help='Patches root volume', action='store_true', required=False)
parser.add_argument('--unpatch_sys_vol', help='Unpatches root volume, EXPERIMENTAL', action='store_true', required=False) parser.add_argument('--unpatch_sys_vol', help='Unpatches root volume, EXPERIMENTAL', action='store_true', required=False)
parser.add_argument('--custom_repo', action='store', help='Set SMBIOS patching mode', required=False)
args = parser.parse_args() args = parser.parse_args()
@@ -139,14 +150,17 @@ class OpenCoreLegacyPatcher():
self.build_opencore() self.build_opencore()
if args.patch_sys_vol: if args.patch_sys_vol:
print("- Set System Volume patching") print("- Set System Volume patching")
if args.custom_repo:
self.constants.url_apple_binaries = args.custom_repo
print(f"- Custom set repo to: {self.constants.url_apple_binaries}")
self.patch_vol() self.patch_vol()
elif args.unpatch_sys_vol: elif args.unpatch_sys_vol:
print("- Set System Volume unpatching") print("- Set System Volume unpatching")
self.unpatch_vol() self.unpatch_vol()
def hexswap(self, input_hex: str):
hex_pairs = [input_hex[i:i + 2] for i in range(0, len(input_hex), 2)]
hex_rev = hex_pairs[::-1]
hex_str = "".join(["".join(x) for x in hex_rev])
return hex_str.upper()
def patch_vol(self): def patch_vol(self):
SysPatch.PatchSysVolume(self.constants.custom_model or self.current_model, self.constants).start_patch() SysPatch.PatchSysVolume(self.constants.custom_model or self.current_model, self.constants).start_patch()

View File

@@ -70,6 +70,7 @@ class BuildOpenCore:
def build_efi(self): def build_efi(self):
Utilities.cls() Utilities.cls()
print(f"Building Configuration for model: {self.model}")
if not Path(self.constants.build_path).exists(): if not Path(self.constants.build_path).exists():
Path(self.constants.build_path).mkdir() Path(self.constants.build_path).mkdir()
print("Created build folder") print("Created build folder")
@@ -585,7 +586,7 @@ class BuildOpenCore:
self.cleanup() self.cleanup()
self.sign_files() self.sign_files()
print("") print("")
print("Your OpenCore EFI has been built at:") print(f"Your OpenCore EFI for {self.model} has been built at:")
print(f" {self.constants.opencore_release_folder}") print(f" {self.constants.opencore_release_folder}")
print("") print("")
if self.constants.gui_mode is False: if self.constants.gui_mode is False:

View File

@@ -31,9 +31,6 @@ Note, when building OpenCore the output folder will be next to the OCLP binary a
### Patch System Arguments ### Patch System Arguments
* **--patch_sys_vol**: patches root volume with detected hardware * **--patch_sys_vol**: patches root volume with detected hardware
* **--custom_repo xxxx**: Sets custom repo for volume patches, defaults to Apple-Binaries-OCLP when no arg provided
* ex. **--custom_repo https://github.com/dortania/Apple-Binaries-OCLP/archive/refs/heads/main.zip**
Example usage: Example usage:

View File

@@ -111,7 +111,7 @@ To aid users in troubleshooting, we've compiled a list of users who've reported
| ^^ | ^^ | AlexSakha67 | - Upgraded R9 280<br/>- Patcher version 0.0.20 | | ^^ | ^^ | AlexSakha67 | - Upgraded R9 280<br/>- Patcher version 0.0.20 |
| ^^ | ^^ | nekton1 | - Upgraded GTX 680<br/>- Patcher version 0.0.20 | | ^^ | ^^ | nekton1 | - Upgraded GTX 680<br/>- Patcher version 0.0.20 |
| ^^ | ^^ | Pri-est | - Patcher version 0.0.9 | | ^^ | ^^ | Pri-est | - Patcher version 0.0.9 |
| ^^ | ^^ | vinaypundith | - Patcher version 0.0.6 | | ^^ | ^^ | vinaypundith | - Upgraded GTX 680<br/>- Upgraded BCM94360CD<br/>- Patcher version 0.0.6 |
| MacPro4,1 | ^^ | ^^ | - Patcher version 0.0.9 | | MacPro4,1 | ^^ | ^^ | - Patcher version 0.0.9 |
| MacPro5,1 | ^^ | woefi | - Upgraded with RX 580<br/>- Patcher version 0.0.21 | | MacPro5,1 | ^^ | woefi | - Upgraded with RX 580<br/>- Patcher version 0.0.21 |
| ^^ | ^^ | Mabrouk Oscar | - Patcher version 0.0.21 | | ^^ | ^^ | Mabrouk Oscar | - Patcher version 0.0.21 |