fixing compilation and class loading errors on win