more cmake fixes for msvc