Changes to compile with Mono on Linux

Minor changes to get build to work with Mono on Linux.  
Fixed code so that build.bat will not fail.