support for MSWin32

This gets it to work on MSWin32.  I also tested it on Linux to guard against any regressions.