How can I setup CMake for use with Visual Studio 2017RC and CUDA 8.0?

后端 未结 2 1690
长情又很酷
长情又很酷 2021-01-23 18:04

Visual Studio 2017 RC includes much tighter CMake integration, allowing one to skip the intermediate step of generating project/solution files and use CMake effectively as the p

相关标签:
2条回答
  • 2021-01-23 18:30

    The very short (and only at the time of writing) answer is that you can't. CUDA 8 doesn't support VS2017. Only VS2015 is presently supported.

    You can always find the compiler/IDE versions which the release version of CUDA supports here

    Edit to add that the CUDA 9 release will add official support for VS2017.

    0 讨论(0)
  • 2021-01-23 18:34

    All you need to do is set the CUDA_HOST_COMPILER variable to a supported compiler for example the visual studio 2015 compiler.

    In my case this is: C:/Program Files (x86)/Microsoft Visual Studio 14.0/VC/bin/amd64/cl.exe

    As both runtime libraries are binary compatible you can use the 2015 compiler within CUDA and compile all the rest of the application with the 2017 compiler.

    0 讨论(0)
提交回复
热议问题