windows build minor fixes, improve win env batch file