adjustments to work on Windows

See comments in commit for related causes that need to be worked around