Add Ventura validation

This commit is contained in:
Mykola Grymalyuk
2022-08-23 11:02:57 -06:00
parent 603b5ee153
commit 763fe04c21
4 changed files with 41 additions and 27 deletions

1
.gitignore vendored
View File

@@ -30,3 +30,4 @@ __pycache__/
/payloads/OpenCore-Legacy-Patcher
/payloads/InstallAssistant.pkg.integrityDataV1
/payloads.dmg
/payloads/OpenCore-Legacy-Patcher-*.plist

View File

@@ -117,15 +117,19 @@ class create_binary:
"AutoPkg-Assets.pkg",
"AutoPkg-Assets.pkg.zip",
"InstallAssistant.pkg",
"InstallAssistant.pkg.integrityDataV1",
]
print("- Deleting extra binaries...")
for file in Path("payloads").glob(pattern="*"):
if file.name in delete_files:
if file.name in delete_files or file.name.startswith("OpenCore-Legacy-Patcher"):
print(f" - Deleting {file.name}")
file.unlink()
elif (Path(file) / Path("Contents/Resources/createinstallmedia")).exists():
print(f" - Deleting {file}")
subprocess.run(["rm", "-rf", file])
elif Path(file).is_dir() and file.name == "Universal-Binaries":
print(f" - Deleting {file}")
subprocess.run(["rm", "-rf", file])
def download_resources(self):
patcher_support_pkg_version = constants.Constants().patcher_support_pkg_version

View File

@@ -2299,7 +2299,8 @@ smbios_dictionary = {
"5K Display": True,
"Stock GPUs": [
device_probe.Intel.Archs.Skylake,
device_probe.AMD.Archs.Legacy_GCN_9000,
device_probe.AMD.Archs.Legacy_GCN_8000,
# System also shipped with Legacy_GCN_9000 (ie. R9 M395X)
],
"Stock Storage": [
"SATA 3.5",

View File

@@ -81,16 +81,19 @@ def validate(settings):
raise Exception(f"Failed to find {source_file}")
print(f"- Validating against Darwin {major_kernel}.{minor_kernel}")
if not sys_patch_helpers.sys_patch_helpers(settings).generate_patchset_plist(patchset, "OpenCore-Legacy-Patcher"):
if not sys_patch_helpers.sys_patch_helpers(settings).generate_patchset_plist(patchset, f"OpenCore-Legacy-Patcher-{major_kernel}.{minor_kernel}.plist"):
raise Exception("Failed to generate patchset plist")
# Remove the plist file after validation
Path(settings.payload_path / f"OpenCore-Legacy-Patcher-{major_kernel}.{minor_kernel}.plist").unlink()
def validate_sys_patch():
if Path(settings.payload_local_binaries_root_path_zip).exists():
print("Validating Root Patch File integrity")
if not Path(settings.payload_local_binaries_root_path).exists():
subprocess.run(["ditto", "-V", "-x", "-k", "--sequesterRsrc", "--rsrc", settings.payload_local_binaries_root_path_zip, settings.payload_path], stdout=subprocess.PIPE, stderr=subprocess.STDOUT)
for supported_os in [os_data.os_data.big_sur, os_data.os_data.monterey]:
for supported_os in [os_data.os_data.big_sur, os_data.os_data.monterey, os_data.os_data.ventura]:
for i in range(0, 10):
validate_root_patch_files(supported_os, i)
print("Validating SNB Board ID patcher")
@@ -99,26 +102,31 @@ def validate(settings):
else:
print("- Skipping Root Patch File integrity validation")
# First run is with default settings
build_prebuilt()
build_dumps()
# Second run, flip all settings
settings.verbose_debug = True
settings.opencore_debug = True
settings.opencore_build = "DEBUG"
settings.kext_debug = True
settings.kext_variant = "DEBUG"
settings.kext_debug = True
settings.showpicker = False
settings.sip_status = False
settings.secure_status = True
settings.firewire_boot = True
settings.nvme_boot = True
settings.enable_wake_on_wlan = True
settings.disable_tb = True
settings.force_surplus = True
settings.software_demux = True
settings.serial_settings = "Minimal"
build_prebuilt()
build_dumps()
validate_sys_patch()
def validate_configs():
# First run is with default settings
build_prebuilt()
build_dumps()
# Second run, flip all settings
settings.verbose_debug = True
settings.opencore_debug = True
settings.opencore_build = "DEBUG"
settings.kext_debug = True
settings.kext_variant = "DEBUG"
settings.kext_debug = True
settings.showpicker = False
settings.sip_status = False
settings.secure_status = True
settings.firewire_boot = True
settings.nvme_boot = True
settings.enable_wake_on_wlan = True
settings.disable_tb = True
settings.force_surplus = True
settings.software_demux = True
settings.serial_settings = "Minimal"
build_prebuilt()
build_dumps()
validate_configs()
validate_sys_patch()