diff --git a/CREDITS.md b/CREDITS.md
new file mode 100644
index 0000000..6e52aab
--- /dev/null
+++ b/CREDITS.md
@@ -0,0 +1,23 @@
+### Credits
+
+* RehabMan, th3joker and others - FakeSMC.kext, https://bitbucket.org/RehabMan
+
+* Chuck Remes (chuckremes) - better documentation
+
+* Meissa - better networking documentation
+
+* PJ Meyer (pjmeyer) - compatibility with modern versions of GNU mktemp
+
+* Robert DeRose (RobertDeRose) and Dirk Bajohr (isolution-de) - macOS support
+
+* Fritz Elfert (felfert) - cleanups, better documentation, and nicer ISO creation script
+
+* Ian McDowell (IMcD23) - more documentation, and better ISO creation script
+
+* voobscout - libvirt XML file
+
+* Evgeny Grin (Karlson2k) - for the original ISO creation script
+
+* Gabriel L. Somlo - for getting things started
+
+* http://www.insanelymac.com/ - Enoch bootloader
diff --git a/README.md b/README.md
index 2821c12..6765450 100644
--- a/README.md
+++ b/README.md
@@ -128,8 +128,7 @@ for a more solid alternate to the following `virsh` method. Use either the
* For better mouse behavior, install https://github.com/pmj/QemuUSBTablet-OSX and
configure QEMU to use the "usb-tablet" absolute pointing device.
-* To get sound on your virtual Mac, install the VoodooHDA driver from
- [here](https://sourceforge.net/projects/voodoohda/files/).
+* To get sound on your virtual Mac, see the "Virtual Sound Device" in [notes](notes.md).
### Debugging
@@ -186,27 +185,7 @@ for a more solid alternate to the following `virsh` method. Use either the
* If the App Store doesn't work, check the [notes file](notes.md) for instructions on how to solve this.
-### Credits
-
-* Chuck Remes (chuckremes) - better documentation
-
-* Meissa - better networking documentation
-
-* PJ Meyer (pjmeyer) - compatibility with modern versions of GNU mktemp
-
-* Robert DeRose (RobertDeRose) and Dirk Bajohr (isolution-de) - macOS support
-
-* Fritz Elfert (felfert) - cleanups, better documentation, and nicer ISO creation script
-
-* Ian McDowell (IMcD23) - more documentation, and better ISO creation script
-
-* voobscout - libvirt XML file
-
-* Evgeny Grin (Karlson2k) - for the original ISO creation script
-
-* Gabriel L. Somlo - for getting things started
-
-* http://www.insanelymac.com/ - Enoch bootloader
+* If you are getting "Dont_Steal_MacOS" related errors, see `FakeSMC installation` section in [notes file](notes.md).
### References
diff --git a/boot-macOS.sh b/boot-macOS.sh
index c275b3c..9d8aac1 100755
--- a/boot-macOS.sh
+++ b/boot-macOS.sh
@@ -17,13 +17,14 @@
# Network device "-device e1000-82545em" can be replaced with "-device vmxnet3"
# for possibly better performance.
-qemu-system-x86_64 -enable-kvm -m 8192 -cpu Penryn,kvm=off,vendor=GenuineIntel \
+qemu-system-x86_64 -enable-kvm -m 3072 -cpu Penryn,kvm=off,vendor=GenuineIntel \
-machine pc-q35-2.4 \
-smp 4,cores=2 \
-usb -device usb-kbd -device usb-mouse \
-device isa-applesmc,osk="ourhardworkbythesewordsguardedpleasedontsteal(c)AppleComputerInc" \
- -kernel ./enoch_rev2848_boot \
+ -kernel ./enoch_rev2877_boot \
-smbios type=2 \
+ -device ich9-intel-hda -device hda-duplex \
-device ide-drive,bus=ide.2,drive=MacHDD \
-drive id=MacHDD,if=none,file=./mac_hdd.img \
-netdev tap,id=net0,ifname=tap0,script=no,downscript=no -device e1000-82545em,netdev=net0,id=net0,mac=52:54:00:c9:18:27 \
diff --git a/create_install_iso.sh b/create_install_iso.sh
index c61ab25..674aa66 100755
--- a/create_install_iso.sh
+++ b/create_install_iso.sh
@@ -503,6 +503,10 @@ else
stage_end_ok "$OSX_inst_ver"
fi
+if [[ "$OSX_inst_ver" =~ 10.12.[4-9] ]]; then
+ exit_with_error "This script might not generate bootable images for versions >= macOS Sierra 10.12.4. Edit this script manually to proceed at your own risk!"
+fi
+
[[ "$OSX_inst_ver" == "10.11" ]] || [[ "$OSX_inst_ver" =~ 10.11.[1-6] ]] || \
echo_warning "Warning! This script is tested only with images of OS X versions 10.11 and 10.11.1-10.11.6. Use at your own risk!"
diff --git a/enoch_rev2877_boot b/enoch_rev2877_boot
new file mode 100644
index 0000000..d958e59
Binary files /dev/null and b/enoch_rev2877_boot differ
diff --git a/kexts/FakeSMC.kext/Contents/Info.plist b/kexts/FakeSMC.kext/Contents/Info.plist
new file mode 100644
index 0000000..ade29f5
--- /dev/null
+++ b/kexts/FakeSMC.kext/Contents/Info.plist
@@ -0,0 +1,284 @@
+
+
+
+
+ BuildMachineOSBuild
+ 16C67
+ CFBundleDevelopmentRegion
+ English
+ CFBundleExecutable
+ FakeSMC
+ CFBundleIdentifier
+ org.netkas.driver.FakeSMC
+ CFBundleInfoDictionaryVersion
+ 6.0
+ CFBundleName
+ FakeSMC
+ CFBundlePackageType
+ KEXT
+ CFBundleShortVersionString
+ 6.24-316-g197d663.1737
+ CFBundleSignature
+ ????
+ CFBundleSupportedPlatforms
+
+ MacOSX
+
+ CFBundleVersion
+ 1737
+ DTCompiler
+ com.apple.compilers.llvm.clang.1_0
+ DTPlatformBuild
+ 8C1002
+ DTPlatformVersion
+ GM
+ DTSDKBuild
+ 12D75
+ DTSDKName
+ macosx10.8
+ DTXcode
+ 0821
+ DTXcodeBuild
+ 8C1002
+ IOKitPersonalities
+
+ FakeSMC
+
+ CFBundleIdentifier
+ org.netkas.driver.FakeSMC
+ Configuration
+
+ Clover
+
+ BEMB
+
+ BEMB
+ flag
+
+ EPCI
+
+ EPCI
+ ui32
+
+ RBr
+
+ RBr
+ ch8*
+
+ REV
+
+ REV
+ {rev
+
+ RPlt
+
+ RPlt
+ ch8*
+
+
+ ExceptionKeys
+
+ CLKH
+ 1
+ CLKT
+ 1
+ MSDW
+ 1
+ NATJ
+ 1
+ NATi
+ 1
+ NTOK
+ 1
+ WKTP
+ 0
+
+ Keys
+
+ $Adr
+
+ ui32
+
+ AAADAA==
+
+
+ $Num
+
+ ui8
+
+ AQ==
+
+
+ ACID
+
+ ch8*
+
+ hfwETdgSevQ=
+
+
+ FNum
+
+ ui8
+
+ AA==
+
+
+ LsNM
+
+ ui8
+
+ AQ==
+
+
+ LsbV
+
+ {rev
+
+ AQQKAAY=
+
+
+ MSSD
+
+ si8
+
+ BQ==
+
+
+ MSSP
+
+ si8
+
+ BQ==
+
+
+ NATJ
+
+ ui8
+
+ AA==
+
+
+ OSK0
+
+ ch8*
+
+ b3VyaGFyZHdvcmtieXRoZXNld29y
+ ZHNndWFyZGVkcGw=
+
+
+ OSK1
+
+ ch8*
+
+ ZWFzZWRvbnRzdGVhbChjKUFwcGxl
+ Q29tcHV0ZXJJbmM=
+
+
+ REV
+
+ {rev
+
+ ATAPAAAD
+
+
+ RVBF
+
+ {rev
+
+ ATAPAAAD
+
+
+ RVUF
+
+ {rev
+
+ ATAPAAAD
+
+
+
+ Types
+
+ BEMB
+ flag
+ CLKC
+ {clc
+ CLKH
+ {clh
+ CLKT
+ ui32
+ CLWK
+ ui32
+ EPCI
+ flag
+ LSSS
+ {lso
+ MSDS
+ ui8
+ MSDW
+ flag
+ MSPS
+ {msp
+ RPlt
+ ch8*
+
+ debug
+
+ smc-compatible
+ smc-napa
+ trace
+
+
+ IOClass
+ FakeSMC
+ IOMatchCategory
+ FakeSMC
+ IOProviderClass
+ AppleACPIPlatformExpert
+ IOResourceMatch
+ FakeSMCKeyStore
+ RM,Build
+ Release-rehabman
+ RM,Version
+ FakeSMC 1737
+
+ FakeSMCKeyStore
+
+ CFBundleIdentifier
+ org.netkas.driver.FakeSMC
+ IOClass
+ FakeSMCKeyStore
+ IOMatchCategory
+ FakeSMCKeyStore
+ IOProviderClass
+ IOResources
+ IOResourceMatch
+ IOKit
+ IOUserClientClass
+ FakeSMCKeyStoreUserClient
+
+
+ NSHumanReadableCopyright
+ Copyright © 2015 netkas. All rights reserved.
+ OSBundleCompatibleVersion
+ 1212
+ OSBundleLibraries
+
+ com.apple.iokit.IOACPIFamily
+ 1.0.0d1
+ com.apple.kpi.bsd
+ 10.6
+ com.apple.kpi.iokit
+ 10.6
+ com.apple.kpi.libkern
+ 10.6
+ com.apple.kpi.mach
+ 10.6
+ com.apple.kpi.unsupported
+ 10.6
+
+ OSBundleRequired
+ Root
+ Source Code
+ "https://github.com/RehabMan/OS-X-FakeSMC-kozlek.git"
+
+
diff --git a/kexts/FakeSMC.kext/Contents/MacOS/FakeSMC b/kexts/FakeSMC.kext/Contents/MacOS/FakeSMC
new file mode 100755
index 0000000..6123fda
Binary files /dev/null and b/kexts/FakeSMC.kext/Contents/MacOS/FakeSMC differ
diff --git a/kexts/QemuUSBTablet-1.2.pkg b/kexts/QemuUSBTablet-1.2.pkg
new file mode 100644
index 0000000..de9f270
Binary files /dev/null and b/kexts/QemuUSBTablet-1.2.pkg differ
diff --git a/kexts/VoodooHDA.kext/Contents/Info.plist b/kexts/VoodooHDA.kext/Contents/Info.plist
new file mode 100755
index 0000000..79d1a74
--- /dev/null
+++ b/kexts/VoodooHDA.kext/Contents/Info.plist
@@ -0,0 +1,145 @@
+
+
+
+
+ BuildMachineOSBuild
+ 11G63
+ CFBundleDevelopmentRegion
+ English
+ CFBundleExecutable
+ VoodooHDA
+ CFBundleIdentifier
+ org.voodoo.driver.VoodooHDA
+ CFBundleInfoDictionaryVersion
+ 6.0
+ CFBundleName
+ VoodooHDA
+ CFBundlePackageType
+ KEXT
+ CFBundleShortVersionString
+ 2.8.9
+ CFBundleSignature
+ ????
+ CFBundleVersion
+ 2.8.9
+ DTCompiler
+
+ DTPlatformBuild
+ 4F1003
+ DTPlatformVersion
+ GM
+ DTSDKBuild
+ 11E52
+ DTSDKName
+ macosx10.7
+ DTXcode
+ 0441
+ DTXcodeBuild
+ 4F1003
+ IOKitPersonalities
+
+ VoodooHDA
+
+ AllowMSI
+
+ Boost
+ 1
+ CFBundleIdentifier
+ org.voodoo.driver.VoodooHDA
+ DisableInputMonitor
+
+ IOClass
+ VoodooHDADevice
+ IOMatchCategory
+ VoodooHDADevice
+ IOPCIClassMatch
+ 0x04020000&0xfffe0000
+ IOProviderClass
+ IOPCIDevice
+ IOUserClientClass
+ VoodooHDAUserClient
+ InhibitCache
+
+ MixerValues
+
+ PCM
+ 90
+ Rec
+ 90
+ iGain
+ 90
+ iMix
+ 90
+
+ NodesToPatch
+
+
+ Caps
+ 0x373e
+ Codec
+ 4
+ Comment
+ Example of possible values
+ Config
+ 0x90a70120
+ Conns
+ 12,13,24
+ Control
+ 20
+ DAC
+ 2
+ Enable
+ 1
+ Node
+ 12
+ Select
+ 13
+ SwitchCh
+ 0
+ Type
+ 4
+
+
+ Codec
+ 2
+ Comment
+ To disable back sound on ALC codec set enable=0
+ Enable
+ 1
+ Node
+ 11
+
+
+ Noise
+ 0
+ Vectorize
+
+ VoodooHDAEnableHalfMicVolumeFix
+
+ VoodooHDAEnableHalfVolumeFix
+
+ VoodooHDAEnableMuteFix
+
+ VoodooHDAEnableVolumeChangeFix
+
+ VoodooHDAVerboseLevel
+ 0
+
+
+ OSBundleLibraries
+
+ com.apple.iokit.IOAudioFamily
+ 1.1fc9
+ com.apple.iokit.IOPCIFamily
+ 2.1
+ com.apple.kpi.iokit
+ 9.0.0
+ com.apple.kpi.libkern
+ 9.0.0
+ com.apple.kpi.mach
+ 9.0.0
+ com.apple.kpi.unsupported
+ 9.0.0
+
+
+
diff --git a/kexts/VoodooHDA.kext/Contents/MacOS/VoodooHDA b/kexts/VoodooHDA.kext/Contents/MacOS/VoodooHDA
new file mode 100755
index 0000000..4e86942
Binary files /dev/null and b/kexts/VoodooHDA.kext/Contents/MacOS/VoodooHDA differ
diff --git a/kexts/VoodooHDA.kext/Contents/PkgInfo b/kexts/VoodooHDA.kext/Contents/PkgInfo
new file mode 100755
index 0000000..bdab95b
--- /dev/null
+++ b/kexts/VoodooHDA.kext/Contents/PkgInfo
@@ -0,0 +1 @@
+KEXT????
\ No newline at end of file
diff --git a/kexts/VoodooHDA.kext/Contents/Resources/English.lproj/InfoPlist.strings b/kexts/VoodooHDA.kext/Contents/Resources/English.lproj/InfoPlist.strings
new file mode 100755
index 0000000..5e45963
Binary files /dev/null and b/kexts/VoodooHDA.kext/Contents/Resources/English.lproj/InfoPlist.strings differ
diff --git a/kexts/VoodooHDA.kext/Contents/Resources/version.plist b/kexts/VoodooHDA.kext/Contents/Resources/version.plist
new file mode 100755
index 0000000..a7095ed
--- /dev/null
+++ b/kexts/VoodooHDA.kext/Contents/Resources/version.plist
@@ -0,0 +1,16 @@
+
+
+
+
+ BuildVersion
+ 1
+ CFBundleShortVersionString
+ 2.8.9
+ CFBundleVersion
+ 2.8.9
+ ProjectName
+ VoodooHDA
+ SourceVersion
+ 0280900
+
+
diff --git a/kexts/versions.txt b/kexts/versions.txt
new file mode 100644
index 0000000..35e8377
--- /dev/null
+++ b/kexts/versions.txt
@@ -0,0 +1,3 @@
+VoodooHDA.kext-289.zip
+
+RehabMan-FakeSMC-2017-0117.zip
diff --git a/macOS-libvirt.xml b/macOS-libvirt.xml
index 9c9cc0c..108f6cd 100644
--- a/macOS-libvirt.xml
+++ b/macOS-libvirt.xml
@@ -44,6 +44,11 @@
+
+
+
+
+
diff --git a/notes.md b/notes.md
index 75f172f..887a453 100644
--- a/notes.md
+++ b/notes.md
@@ -13,6 +13,9 @@ Finally reboot, and then use the App Store without problems.
This fix was found by Glnk2012 of https://www.tonymacx86.com/ site.
+Also tweaking the `SMBios.plist` file using `Chameleon Wizard` can help with
+App Store problems.
+
### Enoch Bootloader
* Download Enoch bootloader from http://www.insanelymac.com/forum/ (requires
@@ -24,6 +27,68 @@ This fix was found by Glnk2012 of https://www.tonymacx86.com/ site.
* Rename boot to enoch_rev####_boot.
+### FakeSMC installation
+
+* Do the following steps as `root` user on the Virtual Machine (VM).
+
+ ```
+ cp -a FakeSMC.kext /System/Library/Extensions/
+ cd /System/Library/Extensions/
+ chmod -R 755 FakeSMC.kext
+ chown -R root:wheel FakeSMC.kext
+ rm -R /System/Library/Caches/com.apple.kext.caches
+ touch /System/Library/Extensions && kextcache -u / # optional step
+ ```
+
+* Remove the `-device isa-applesmc,osk=... \` line completely from `boot*.sh` file(s).
+
+* If you are using the `virsh` boot method, then remove the following lines from your `virsh` XML file,
+
+ ```
+
+
+ ```
+
+* Reboot the VM for changes to take effect. Use `kextstat` to verify that `FakeSMC.kext` is loaded.
+
+* Latest `FakeSMC.kext` version can be downloaded from [this location](https://bitbucket.org/RehabMan/os-x-fakesmc-kozlek).
+
+* If your updated VM is failing to boot and it doesn't have `FakeSMC.kext` installed, the following steps can used to inject `FakeSMC.kext` into the VM disk image,
+
+ ```
+ $ sudo modprobe nbd # all steps to be executed on the QEMU/KVM host
+
+ $ sudo qemu-nbd -c /dev/nbd0 -n mac_hdd.img
+
+ $ sudo fdisk -l /dev/nbd0
+ ...
+ Device Start End Sectors Size Type
+ /dev/nbd0p1 40 409639 409600 200M EFI System
+ /dev/nbd0p2 409640 132948151 132538512 63.2G Apple HFS/HFS+
+ /dev/nbd0p3 132948152 134217687 1269536 619.9M Apple boot
+
+ $ sudo kpartx -a /dev/nbd0
+
+ $ mkdir mnt
+
+ $ sudo mount -t hfsplus -o force,rw /dev/mapper/nbd0p2 mnt
+
+ $ cd mnt
+
+ $ ls
+ Applications bin Chameleon.Backups cores dev etc...
+
+ # Install FakeSMC.kext using the above mentioned steps
+
+ $ cd ..
+
+ $ sudo umount mnt
+
+ $ sudo kpartx -d /dev/nbd0
+
+ $ sudo qemu-nbd -d /dev/nbd0
+ ```
+
### Enoch Bootloader (alternate extraction method)
* Build xar from http://mackyle.github.io/xar/ on a Linux box.
@@ -69,11 +134,37 @@ is provided for this unmaintained project!
vmw_options_fb=0x06
```
-Thanks to Kfir Ozer for finding this.
+Thanks to Zhang Tong and Kfir Ozer for finding this.
GPU passthrough is out of scope for this project. No support for it is provided
whatsoever.
+### Virtual Sound Device
+
+No support is provided for this. You are on your own. The sound output is known
+to be choppy and distorted.
+
+* Add `-device ich9-intel-hda -device hda-duplex` to the VM configuration.
+ `boot-macOS.sh` already has this change.
+
+* To get sound on your virtual Mac, install the VoodooHDA driver from
+ [here](https://sourceforge.net/projects/voodoohda/files/).
+
+
+### Building QEMU from source
+
+See http://wiki.qemu-project.org/Hosts/Linux for help.
+
+```
+$ git clone https://github.com/qemu/qemu.git
+
+$ cd qemu
+
+$ ./configure --prefix=/home/$(whoami)/QEMU --target-list=x86_64-softmmu --audio-drv-list=pa
+
+$ make clean; make; make install
+```
+
### Boot Notes
Type the following after boot,
@@ -117,3 +208,5 @@ Release Date: October 21, 2015
``jar -xf `` is pretty neat.
Move 'InstallESD.dmg' to '/Applications/Install OS X El Capitan.app/Contents/SharedSupport/InstallESD.dmg' location.
+
+Move 'InstallESD.dmg' to '/Applications/Install macOS Sierra.app/Contents/SharedSupport/' location (for macOS Sierra).