Merge upstream and fix some compile errors. No guarentee kali still works, I guessed at part of it.
Commit more upstream, reverting a bit of local stuff so upstream matching is better. Clean all endline whitespace to make merging and maintanance easier.
Merge up to current upstream. Passes compiles tests.