I set the linker and the search directories to point to the libcufft.so and the above include files
when I compile I have the following error generated:
Compiling: FFT_main.cpp
/…/cuda.h:547: error: expected ‘,’ or ‘…’ before numeric constant
/…/cuda.h:696: error: expected ‘,’ or ‘…’ before numeric constant
the first line (547) in cuda.h is under device management
CUresult CUDAAPI cuDeviceGetAttribute(int *pi, CUdevice_attribute attrib, CUdevice dev);
the second line (696) in cuda.h is under fuction management
CUresult CUDAAPI cuFuncGetAttribute (int *pi, CUfunction_attribute attrib, CUfunction hfunc);
I Understand that everybody is busy developing their own code; so I decided to do a little more work.
I wrote a new code utilizing the CUFFT library and added the memory copy command to transfer the data from the host to device and back.
I implemented the code for 3d and it works fine. Therefor I made the necessary changes in the primary project I am doing and … I am still getting the same error! >.<
When I investigated more I found that the compiler pointing the error @ the int *pi part in the following line (listed above too)
Maybe you should try adjusting the include statements.
For my case, I wrap the calls with cutilSafeCall() or cufftSafeCall()s and I include cufft.h and cutil_inline.h, but not cuda.h or cuda_runtime.h and my code works fine.