cannot locate curand_kernel.h

Hi

I am a newbie of CUDA (but I really want to learn). I tried to install the various packages for my Linux distribution (Ubuntu 10.04) so I have downloaded
the driver from here:
http://developer.download.nvidia.com/compute/cuda/3_2/drivers/devdriver_3.2_linux_64_260.19.14.run

and the toolkit 3.2 RC2 from here:
http://www.nvidia.com/object/thankyou.html?url=/compute/cuda/3_2/toolkit/cudatoolkit_3.2.12_linux_64_ubuntu10.04.run

Unfortunately, after the installation, if I run “locate curand_kernel.h” (this is just one of the library that I need) from the base ("/") I can’t find this file.

So, did something go wrong during the installation or these libraries are not included in the linux version of the toolkit?

Does anyone have a solution for this problem?

Is it just me??

Hi

I am a newbie of CUDA (but I really want to learn). I tried to install the various packages for my Linux distribution (Ubuntu 10.04) so I have downloaded
the driver from here:
http://developer.download.nvidia.com/compute/cuda/3_2/drivers/devdriver_3.2_linux_64_260.19.14.run

and the toolkit 3.2 RC2 from here:
http://www.nvidia.com/object/thankyou.html?url=/compute/cuda/3_2/toolkit/cudatoolkit_3.2.12_linux_64_ubuntu10.04.run

Unfortunately, after the installation, if I run “locate curand_kernel.h” (this is just one of the library that I need) from the base ("/") I can’t find this file.

So, did something go wrong during the installation or these libraries are not included in the linux version of the toolkit?

Does anyone have a solution for this problem?

Is it just me??

The header file is not the library.

When you compile, just add the location of the directories with the include files (-I) and libraries (-L).
If you are using nvcc, there is no need to pass the /usr/local/cuda/include

nvcc -o mytest test.cu -L/usr/local/cuda/lib64 -lcurand

The header file is not the library.

When you compile, just add the location of the directories with the include files (-I) and libraries (-L).
If you are using nvcc, there is no need to pass the /usr/local/cuda/include

nvcc -o mytest test.cu -L/usr/local/cuda/lib64 -lcurand

Thanks for your reply.

I have just tried to compile my code including the lib64 directory as you suggested but this is what I get:

nvcc unf_max_cuda_krand.cu -L/usr/local/cuda/lib64 -lcurand -o unf_cuda_rand_k

unf_max_cuda_krand.cu:6:27: error: curand_kernel.h: No such file or directory

I tried to remove the “#include curand_kernel.h” but in this case I get a lot of errors.

This is what I have in the lib64 directory:

nanoscope@lpmvpc25:/usr/local/cuda/lib64$ ls

libcublasemu.so      libcublas.so.2    libcudart.so.2.3    libcufft.so

libcublasemu.so.2    libcublas.so.2.3  libcufftemu.so      libcufft.so.2

libcublasemu.so.2.3  libcudart.so      libcufftemu.so.2    libcufft.so.2.3

libcublas.so         libcudart.so.2    libcufftemu.so.2.3

I can’t see the curand. Any suggestions?

Thanks for your reply.

I have just tried to compile my code including the lib64 directory as you suggested but this is what I get:

nvcc unf_max_cuda_krand.cu -L/usr/local/cuda/lib64 -lcurand -o unf_cuda_rand_k

unf_max_cuda_krand.cu:6:27: error: curand_kernel.h: No such file or directory

I tried to remove the “#include curand_kernel.h” but in this case I get a lot of errors.

This is what I have in the lib64 directory:

nanoscope@lpmvpc25:/usr/local/cuda/lib64$ ls

libcublasemu.so      libcublas.so.2    libcudart.so.2.3    libcufft.so

libcublasemu.so.2    libcublas.so.2.3  libcufftemu.so      libcufft.so.2

libcublasemu.so.2.3  libcudart.so      libcufftemu.so.2    libcufft.so.2.3

libcublas.so         libcudart.so.2    libcufftemu.so.2.3

I can’t see the curand. Any suggestions?

Your version of CUDA is too old (2.3).
If I remember correctly CURAND was included in 3.1. It is in 3.2 for sure.

Your version of CUDA is too old (2.3).
If I remember correctly CURAND was included in 3.1. It is in 3.2 for sure.