Hi everyone,
I am trying to compile a static library (statically linked with CUDA) as plug-in to inject in another program.
At the beginning, for easiness, I adapted one (Windows) VS Solution files everyone can get from NVIDIA CUDA examples. However, I now would like to understand a bit more in detail how a CUDA compilation actually works, so I switched to command line compilation.
specifying --compile indicates compile only. You aren’t linking anything there. That step by itself isn’t sufficient to create a linked library. So it’s also rather curious to me that you have --linker-options in there.
It’s not really clear if the command you have shown is the command that is producing the C1083 error or if it is coming from some subsequent command you have issued. If you want help with something like this, my advice is to include the full console output rather than just the error, showing all the commands that led up to that error.
If you want to see how to build a static library using the command line, one possible approach is to set one up in VS, then study the output console carefully.
I had the same doubt while doing it (say, I don’t use compilers daily, but close), but I don’t know why I mis-interpreted the help message displayed by nvcc. My bad there.
Same for --linker-options…