Fix all warnings for native and qemu-i386

Missing returns, unused variables (only used for debugging), empty
translation units, missing function prototypes, and GNU extensions.
Merge pull request #1335 from Kijewski/fix-all-warnings-for-native-and-qemu-i386

Fix all warnings for native and qemu-i386