Set default darwin versions for missing MaxKernel and MinKernel information

Fixed #61
This commit is contained in:
Hoang Hong Quan
2024-11-17 20:29:49 +07:00
parent 49c3335187
commit a371ee012e
+2 -2
View File
@@ -370,8 +370,8 @@ class KextMaestro:
if dep_identifier in bundle_dict: if dep_identifier in bundle_dict:
visit(bundle_dict[dep_identifier]) visit(bundle_dict[dep_identifier])
bundle["MaxKernel"] = bundle["MaxKernel"] if self.utils.parse_darwin_version(bundle["MaxKernel"]) < self.utils.parse_darwin_version(bundle_dict[dep_identifier]["MaxKernel"]) else bundle_dict[dep_identifier]["MaxKernel"] bundle["MaxKernel"] = bundle["MaxKernel"] if self.utils.parse_darwin_version(bundle["MaxKernel"]) < self.utils.parse_darwin_version(bundle_dict[dep_identifier].get("MaxKernel", "99.99.99")) else bundle_dict[dep_identifier]["MaxKernel"]
bundle["MinKernel"] = bundle["MinKernel"] if self.utils.parse_darwin_version(bundle["MinKernel"]) > self.utils.parse_darwin_version(bundle_dict[dep_identifier]["MinKernel"]) else bundle_dict[dep_identifier]["MinKernel"] bundle["MinKernel"] = bundle["MinKernel"] if self.utils.parse_darwin_version(bundle["MinKernel"]) > self.utils.parse_darwin_version(bundle_dict[dep_identifier].get("MinKernel", "0.0.0")) else bundle_dict[dep_identifier]["MinKernel"]
if os.path.splitext(os.path.basename(bundle.get("BundlePath")))[0] == "AirPortBrcm4360_Injector": if os.path.splitext(os.path.basename(bundle.get("BundlePath")))[0] == "AirPortBrcm4360_Injector":
bundle["MaxKernel"] = "19.99.99" bundle["MaxKernel"] = "19.99.99"