You don't disable that kind of integrity check, you simply set the checksum. The one that's relevant in this particular case is the respective field in the
IMAGE_OPTIONAL_HEADER, that is
That said, you will likely run into additional issues once you resolved this one. I am not sure if the kernel itself is subject to Early Launch scans, but I reckon there's a reason why these binaries are also code-signed. So at the very least you may want to disable the integrity checks altogether from an elevated prompt:
bcdedit.exe /set nointegritychecks on (make sure to reboot afterwards).
Various functions can be used to compute a checksum for a PE file. The probably easiest method is using the Image Help Library function
MapFileAndCheckSum() or alternatively (
CheckSumMappedFile()). If I remember correctly there are a few more, including one
Ldr* function from
ntdll.dll which can be used to that end.