provide a VS2012 project and fix compilation issues