Changes to be able to compile on Windows