modifications to build under MSVSExp 2012. 64bit build doesn't yet work