CMake support for Windows/MSVC

Same request as #938, in next.