[cygwin] misc fixes to get things building/running on windows

This change is just a first step, it should get the basics going.  But,
the tests don't all build and there are probably other issues when
running.