Added some code to make compiling for windows easier (for me).