I am trying to compile a CUDA 5.5 application on nsight with ubuntu 12.04
At first I was getting an issue about missing header files such as #include <helper_cuda_drvapi.h>
To fix this I added the path /usr/include/samples/common/inc to my includes list.
This solved the missing header file issue but caused a new issue.
when trying to compile the program on nsight I get the following errors
/usr/local/cuda-5.5/samples/common/inc/helper_cuda_drvapi.h:278: undefined reference to
cuInit' /usr/local/cuda-5.5/samples/common/inc/helper_cuda_drvapi.h:279: undefined reference tocuDeviceGetCount' /usr/local/cuda-5.5/samples/common/inc/helper_cuda_drvapi.h:290: undefined reference tocuDeviceGetName' /usr/local/cuda-5.5/samples/common/inc/helper_cuda_drvapi.h:291: undefined reference tocuDeviceComputeCapability' /usr/local/cuda-5.5/samples/common/inc/helper_cuda_drvapi.h:294: undefined reference tocuDeviceGetAttribute' /usr/local/cuda-5.5/samples/common/inc/helper_cuda_drvapi.h:327: undefined reference tocuDeviceGetAttribute' /usr/local/cuda-5.5/samples/common/inc/helper_cuda_drvapi.h:330: undefined reference tocuDeviceGetAttribute' /usr/local/cuda-5.5/samples/common/inc/helper_cuda_drvapi.h:333: undefined reference tocuDeviceComputeCapability' /usr/local/cuda-5.5/samples/common/inc/helper_cuda_drvapi.h:336: undefined reference to `cuDeviceGetAttribute'
any suggestions?
Thanks in advance
*****************UPDATE************
What it basically comes down to is I am trying to compile the "CUDA Video Decoder GL API" sample program on linux and it is not working because of some error with the header files. Does anyone know why this is?
UPDATE





cuda.handcuda_runtime.hbeforehelper_cuda_drvapi.h. - Roger Dahlhelper_cuda_drvapi.h, being part of the sample framework, is intended for use only from.cufiles and so doesn't include cuda.h itself? - Roger Dahl