Can't compile CUDA 4RC sample programs

I just downloaded and installed CUDA 4.0.13 (linux 64) for the first time. I’m running ubuntu 10.10 with the 260.19.06 Nvidia driver on a machine with a Quadro 600. The install seemed to go find until I tried to compile the sample programs included with the SDK. The compilation errors out with a number of undefined references. Any help would be great. I’ve posted the compilation results below.

make
make[1]: Entering directory /home/tjacobs2/NVIDIA_GPU_Computing_SDK/C/common' make[1]: Leaving directory /home/tjacobs2/NVIDIA_GPU_Computing_SDK/C/common’
make[1]: Entering directory /home/tjacobs2/NVIDIA_GPU_Computing_SDK/C/common' make[1]: Leaving directory /home/tjacobs2/NVIDIA_GPU_Computing_SDK/C/common’
make[1]: Entering directory /home/tjacobs2/NVIDIA_GPU_Computing_SDK/C/common' make[1]: Leaving directory /home/tjacobs2/NVIDIA_GPU_Computing_SDK/C/common’
make[1]: Entering directory /home/tjacobs2/NVIDIA_GPU_Computing_SDK/shared' make[1]: Leaving directory /home/tjacobs2/NVIDIA_GPU_Computing_SDK/shared’
make -C src/eigenvalues/
make[1]: Entering directory /home/tjacobs2/NVIDIA_GPU_Computing_SDK/C/src/eigenvalues' make[1]: Leaving directory /home/tjacobs2/NVIDIA_GPU_Computing_SDK/C/src/eigenvalues’
make -C src/asyncAPI/
make[1]: Entering directory /home/tjacobs2/NVIDIA_GPU_Computing_SDK/C/src/asyncAPI' make[1]: Leaving directory /home/tjacobs2/NVIDIA_GPU_Computing_SDK/C/src/asyncAPI’
make -C src/simpleMultiCopy/
make[1]: Entering directory /home/tjacobs2/NVIDIA_GPU_Computing_SDK/C/src/simpleMultiCopy' make[1]: Leaving directory /home/tjacobs2/NVIDIA_GPU_Computing_SDK/C/src/simpleMultiCopy’
make -C src/fluidsGL/
make[1]: Entering directory /home/tjacobs2/NVIDIA_GPU_Computing_SDK/C/src/fluidsGL' make[1]: Leaving directory /home/tjacobs2/NVIDIA_GPU_Computing_SDK/C/src/fluidsGL’
make -C src/reduction/
make[1]: Entering directory /home/tjacobs2/NVIDIA_GPU_Computing_SDK/C/src/reduction' make[1]: Leaving directory /home/tjacobs2/NVIDIA_GPU_Computing_SDK/C/src/reduction’
make -C src/SobelFilter/
make[1]: Entering directory /home/tjacobs2/NVIDIA_GPU_Computing_SDK/C/src/SobelFilter' make[1]: Leaving directory /home/tjacobs2/NVIDIA_GPU_Computing_SDK/C/src/SobelFilter’
make -C src/dxtc/
make[1]: Entering directory /home/tjacobs2/NVIDIA_GPU_Computing_SDK/C/src/dxtc' make[1]: Leaving directory /home/tjacobs2/NVIDIA_GPU_Computing_SDK/C/src/dxtc’
make -C src/simpleSurfaceWrite/
make[1]: Entering directory /home/tjacobs2/NVIDIA_GPU_Computing_SDK/C/src/simpleSurfaceWrite' make[1]: Leaving directory /home/tjacobs2/NVIDIA_GPU_Computing_SDK/C/src/simpleSurfaceWrite’
make -C src/simpleStreams/
make[1]: Entering directory /home/tjacobs2/NVIDIA_GPU_Computing_SDK/C/src/simpleStreams' make[1]: Leaving directory /home/tjacobs2/NVIDIA_GPU_Computing_SDK/C/src/simpleStreams’
make -C src/threadMigration/
make[1]: Entering directory /home/tjacobs2/NVIDIA_GPU_Computing_SDK/C/src/threadMigration' [b]obj/x86_64/release/threadMigration.cpp.o: In function FinalErrorCheck(int, int, int)’:
threadMigration.cpp:(.text+0x59): undefined reference to cuCtxDestroy_v2' obj/x86_64/release/threadMigration.cpp.o: In function runTest(int, char**)’:
threadMigration.cpp:(.text+0x6f6): undefined reference to cuCtxPopCurrent_v2' obj/x86_64/release/threadMigration.cpp.o: In function ThreadProc(_CUDAContext_st*)’:
threadMigration.cpp:(.text+0x1012): undefined reference to cuCtxPushCurrent_v2' threadMigration.cpp:(.text+0x1096): undefined reference to cuLaunchKernel’
threadMigration.cpp:(.text+0x1164): undefined reference to cuCtxPopCurrent_v2'[/b] collect2: ld returned 1 exit status make[1]: *** [../../bin/linux/release/threadMigration] Error 1 make[1]: Leaving directory /home/tjacobs2/NVIDIA_GPU_Computing_SDK/C/src/threadMigration’
make: *** [src/threadMigration/Makefile.ph_build] Error 2

Thanks,
Tim

The driver you are using is far too old to support CUDA 4.0. You must use one of the 270 series development drivers that are available with the toolkit for download (I think 270.40 is the “official” 4.0rc2 driver). The error you are seeing stems from linking against an old version of the cuda driver api library.

Thanks for the info. I checked the release notes and couldn’t find the required version. I figured that might be the issue. I’ve updated my drivers and things seem to be working now.

-Tim