[CMake] VS 2017 + CUDA 9.0

Sophonet cmake at kant.sophonet.de
Thu Aug 2 16:00:07 EDT 2018


Hi list,

it seems that Cuda 9.0 has problems with VS 2017 (5.5 upwards) and requires an old toolset to be installed for successful compilation (15.4, see https://blogs.msdn.microsoft.com/vcblog/2017/11/15/side-by-side-minor-version-msvc-toolsets-in-visual-studio-2017/). The new VS 2017 toolset have an incompatible _MSC_VER variable, among other things.

The link above mentions to manually revert the toolset for a solution, but I was wondering how CMake-based projects could be configured to automatically pick the 15.4 toolset (which has version 14.11 instead of 14.12). The CMake documentation for toolsets is somehow sparse and only mentions toolsets with name „v141“, which I think would apply for both. Any hints to find out (i) what toolsets are actually available for a specific compiler or (ii) forcing toolset 14.12 as mentioned above - without manual editing of the vcproj project files?

Thanks,

	Sophonet




More information about the CMake mailing list