Fixes for windows build and updated cmake build

All the fixes needed to allow create_projects_win.bat to create a buildable and runnable moai