Remove more ifdefs from the include files.
Remove more ifdefs from the headers.
Fix a build error in the kinet plugin on BSD.
Resync with trunk