-
Notifications
You must be signed in to change notification settings - Fork 86
/
install_downloads.sh
executable file
·55 lines (42 loc) · 1.59 KB
/
install_downloads.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
#!/bin/bash
#set -x
EXCEPTIONS="NullEthernetInjector"
ESSENTIAL="AppleALC.kext CodecCommander.kext"
# include subroutines
source "$(dirname ${BASH_SOURCE[0]})"/_tools/_install_subs.sh
warn_about_superuser
# install tools
install_tools
# remove old/not used kexts
remove_deprecated_kexts
# EHCI is disabled, so no need for FakePCIID_XHCIMux.kext
remove_kext FakePCIID_XHCIMux.kext
# using AppleALC.kext, remove patched zml.zlib files
sudo rm -f /System/Library/Extensions/AppleHDA.kext/Contents/Resources/*.zml.zlib
# install required kexts
install_download_kexts
install_brcmpatchram_kexts
install_fakepciid_intel_hdmi_audio
# install other common kexts
install_kext _tools/kexts/XHCI-unsupported.kext
install_kext _tools/kexts/SATA-unsupported.kext
# install NVMeGeneric.kext if it is found in Clover/kexts
# patch it so it is marked OSBundleRequired=Root
# Note: NVMeGeneric.kext is NOT recommended
EFI="$(./mount_efi.sh)"
if [[ -e "$EFI/EFI/CLOVER/kexts/Other/NVMeGeneric.kext" ]]; then
cp -Rf "$EFI/EFI/CLOVER/kexts/Other/NVMeGeneric.kext" /tmp/NVMeGeneric.kext
/usr/libexec/PlistBuddy -c "Add :OSBundleRequired string" /tmp/NVMeGeneric.kext/Contents/Info.plist
/usr/libexec/PlistBuddy -c "Set :OSBundleRequired Root" /tmp/NVMeGeneric.kext/Contents/Info.plist
install_kext /tmp/NVMeGeneric.kext
fi
# install HackrNVMEFamily-.* if it is found in Clover/kexts
kext="$(echo "$EFI"/EFI/CLOVER/kexts/Other/HackrNVMeFamily-*.kext)"
if [[ -e "$kext" ]]; then
install_kext "$kext"
fi
# LiluFriend and kernel cache rebuild
finish_kexts
# update kexts on EFI/CLOVER/kexts/Other
update_efi_kexts
#EOF