How to generate .ptx file from .cu file in a visual studio project?

I installed CUDA and optix. Also, I had compiled the sample code successfully. But when I tried to create a new project, I got stuck with the setup for .cu files while uses “custom build” to produce ptx file. I found that custom build is using a cmake file which seems to be generated for that particular .cu file. If there any tool to make that cmake file?? or is there any easy syntax to create .ptx file from .cu file.??

1 Like