Fixed cmake build to work with Windows