More fixes for cygwin builds