minor fixes for Cygwin