Issue
I use cmake to build C++ project. I didn't add "/Zi" compile option to CMAKE_CUDA_FLAGS. But Visual Studio add "/Zi" to CUDA Linker automatically. My library will become pretty big with this option, so how can I remove it?
Solution
CUDA Visual Studio Integration doesn't make /Zi
configurable by default.
You can either modify HostCommandLineTemplate
, RuntimeApiCommandLineTemplate
, and CommandLineTemplate
directly in C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\V140\BuildCustomizations\CUDA 10.0.props
or specify an extra .props
file to customize your build according to Visual Studio Customize your build.
Just in case, Here is also an example for customize VS build properties using cmake.
Answered By - expoter