CUDA sdk installation

Hi,

I have been trying to compile the CUDA-sdk examples on my linux machines.

I was following steps:

a) installed cuda driver 3.2 [devdriver_3.2_linux_64_260.19.26.run]

b) installed nvidia sdk 3.2 [gpucomputingsdk_3.2.16_linux.run]

c) cd NVIDIA_GPU_Computing_SDK/C/

d) make clean; make

Errors and fixes.

[1] for the first make I got error that cuda.h is not found.

 To fix that i included -I/usr/include/cuda in common/common.mk

[2] Second i got the error

In function ‘void surf1Dread(T*, surface<void, 1>, int, int, cudaSurfaceBoundaryMode)’:
/usr/include/surface_functions.h:100: error: there are no arguments to ‘__surf1Dreadc1’ that depend on a template parameter, so a declaration of ‘__surf1Dreadc1’ must be available
/usr/include/surface_functions.h:100: error: (if you use ‘-fpermissive’, G++ will accept your code, but allowing the use of an undeclared name is deprecated)
/usr/include/surface_functions.h:101: error: there are no arguments to ‘__surf1Dreads1’ that depend on a template parameter, so a declaration of ‘__surf1Dreads1’ must be available
/usr/include/surface_functions.h:102: error: there are no arguments to ‘__surf1Dreadu1’ that depend on a template parameter, so a declaration of ‘__surf1Dreadu1’ must be available
/usr/include/surface_functions.h:103: error: there are no arguments to ‘__surf1Dreadu2’ that depend on a template parameter, so a declaration of ‘__surf1Dreadu2’ must be available
/usr/include/surface_functions.h:104: error: there are no arguments to ‘__surf1Dreadu4’ that depend on a template parameter, so a declaration of ‘__surf1Dreadu4’ must be available
/usr/include/surface_functions.h: In function ‘void surf2Dread(T*, surface<void, 2>, int, int, int, cudaSurfaceBoundaryMode)’:
/usr/include/surface_functions.h:460: error: there are no arguments to ‘__surf2Dreadc1’ that depend on a template parameter, so a declaration of ‘__surf2Dreadc1’ must be available
/usr/include/surface_functions.h:461: error: there are no arguments to ‘__surf2Dreads1’ that depend on a template parameter, so a declaration of ‘__surf2Dreads1’ must be available
/usr/include/surface_functions.h:462: error: there are no arguments to ‘__surf2Dreadu1’ that depend on a template parameter, so a declaration of ‘__surf2Dreadu1’ must be available
/usr/include/surface_functions.h:463: error: there are no arguments to ‘__surf2Dreadu2’ that depend on a template parameter, so a declaration of ‘__surf2Dreadu2’ must be available
/usr/include/surface_functions.h:464: error: there are no arguments to ‘__surf2Dreadu4’ that depend on a template parameter, so a declaration of ‘__surf2Dreadu4’ must be available

To fix this i used --compiler-options -fpermissive in common/common.mk

[3] After fixing [2] error, I got another error as follows.

deviceQueryDrv.cpp: In function ‘int main(int, char**)’:
deviceQueryDrv.cpp:70: error: cannot convert ‘size_t*’ to ‘unsigned int*’ for argument ‘1’ to ‘CUresult cuDeviceTotalMem(unsigned int*, CUdevice)’

I am not sure, if I am doing right stuff here.

Any help would be much appreciated.

thanks,
-pkb

DId you install cuda toolkit before compiling SDK ?