Relatively minor changes to get windows binaries building