Add NightShiftEnabler support

Closes https://github.com/dortania/Opencore-Legacy-Patcher/issues/80
This commit is contained in:
Mykola Grymalyuk
2021-03-06 15:22:47 -07:00
parent 1af5182560
commit a7ebf72d1b
7 changed files with 42 additions and 2 deletions

View File

@@ -4,6 +4,7 @@
- Enable ThirdPartyDrives to aid with hibernation on 3rd party SATA drives
- Increment OpenCore 7bb41aa (0.6.8 rolling, 2021-03-06)
- Add ForceBooterSignature to resolve hibernation issues
- Add NightShiftEnabler (1.1.0 release e1639f9)
## 0.0.13
- Add CPUFriend support to resolve X86PlatformPlugin clashes

View File

@@ -49,7 +49,8 @@ system_profiler SPHardwareDataType | grep 'Model Identifier'
- Khronokernel:\tWriting and maintaining this patcher
- DhinakG:\t\tWriting and maintaining this patcher
- Syncretic:\t\tAAAMouSSE and telemetrap
- Slice:\t\tVoodooHDA"""]).start()
- Slice:\t\tVoodooHDA
- cdf:\t\tNightShiftEnabler"""]).start()
def main_menu(self):
response = None

View File

@@ -27,6 +27,7 @@ class Constants:
self.piixata_version = "1.0.0"
self.backlight_version = "1.0.0"
self.cpufriend_version = "1.2.3"
self.nightshift_version = "1.1.0"
# Get resource path
self.current_path = Path(__file__).parent.parent.resolve()
@@ -91,6 +92,8 @@ class Constants:
def backlight_path(self): return self.payload_kexts_path / Path(f"Misc/AppleBacklightFixup-v{self.backlight_version}.zip")
@property
def cpufriend_path(self): return self.payload_kexts_path / Path(f"Acidanthera/CPUFriend-v{self.cpufriend_version}.zip")
@property
def nightshift_path(self): return self.payload_kexts_path / Path(f"Misc/NightShiftEnabler-v{self.nightshift_version}.zip")
# Build Location
@property

View File

@@ -777,4 +777,20 @@ X86PP = [
"iMac14,1",
"iMac14,2",
"iMac14,3",
]
NightShiftExclude = [
"MacBookAir5,1",
"MacBookAir5,2",
"MacBookPro9,1",
"MacBookPro9,2",
"MacBookPro10,1",
"MacBookPro10,2",
"Macmini6,1",
"Macmini6,2",
"iMac13,1",
"iMac13,2",
"iMac14,1",
"iMac14,2",
"iMac14,3",
]

View File

@@ -75,6 +75,7 @@ class BuildOpenCore:
("Lilu.kext", self.constants.lilu_version, self.constants.lilu_path, lambda: True),
("WhateverGreen.kext", self.constants.whatevergreen_version, self.constants.whatevergreen_path, lambda: True),
("RestrictEvents.kext", self.constants.restrictevents_version, self.constants.restrictevents_path, lambda: self.model in ModelArray.MacPro71),
("NightShiftEnabler.kext", self.constants.nightshift_version, self.constants.nightshift_path, lambda: self.model not in ModelArray.NightShiftExclude),
# CPU patches
("AppleMCEReporterDisabler.kext", self.constants.mce_version, self.constants.mce_path, lambda: self.model in ModelArray.DualSocket),
("AAAMouSSE.kext", self.constants.mousse_version, self.constants.mousse_path, lambda: self.model in ModelArray.SSEEmulator),

View File

@@ -504,6 +504,24 @@
<key>PlistPath</key>
<string>Contents/Info.plist</string>
</dict>
<dict>
<key>Arch</key>
<string>x86_64</string>
<key>Comment</key>
<string>NightShiftEnabler</string>
<key>Enabled</key>
<false/>
<key>MaxKernel</key>
<string></string>
<key>MinKernel</key>
<string></string>
<key>BundlePath</key>
<string>NightShiftEnabler.kext</string>
<key>ExecutablePath</key>
<string>Contents/MacOS/NightShiftEnabler</string>
<key>PlistPath</key>
<string>Contents/Info.plist</string>
</dict>
<dict>
<key>Arch</key>
<string>x86_64</string>
@@ -669,7 +687,7 @@
<key>ConsoleAttributes</key>
<integer>0</integer>
<key>HibernateMode</key>
<string>Auto</string>
<string>None</string>
<key>HideAuxiliary</key>
<true/>
<key>LauncherPath</key>

Binary file not shown.