Issue #82 and Issue #83: towards a working cygwin/windows build