Hybrid CUDA runtime linking

Hello,

since CUDA Toolkit version 13.2 linking with the flag -cudart=shared is deprecated on Windows and has been replaced with -cudart=hybrid. From the nvidia docs:

How can I set the flag with CMake? Before I would use

set(CMAKE_CUDA_RUNTIME_LIBRARY Shared)

but this now causes the warning

‘shared’ is a deprecated value for option ‘–cudart (-cudart)’. Use ‘hybrid’ instead.

when I compile with Visual Studio + CUDA 13.2. I tried setting

set(CMAKE_CUDA_RUNTIME_LIBRARY Hybrid)

but that does not seem to work correctly. The latest CMake documentation on CMAKE_CUDA_RUNTIME_LIBRARY also does not mention hybrid linking.

Any ideas to set this flag correctly? Thank you