Some src modifications for windows build.