Create platform.h
Fix fucking macros finally.

Took me fucking ages, and I was too retarded to write a macro to handle
this.