Derek
Derek

Reputation: 11915

CUDA 4.0 SDK missing files?

I have been trying to compile the CUDA 4.0 SDK examples. I am getting an error:

make[2]: Entering directory `/home/dcole/software/cudaSDK/CUDALibraries/common/UtilNPP'
In file included from ImageIO.h:32,
                 from ImageIO.cpp:30:
ImagesCPU.h:37:17: error: npp.h: No such file or directory
In file included from ImagesNPP.h:35,
                 from ImageIO.h:33,
                 from ImageIO.cpp:30:
ImageAllocatorsNPP.h:34:18: error: nppi.h: No such file or directory

Have I missed installing something as part of the SDK? I untarred cudatools and the gpucomputingSDK all into the same root directory. Is this the right thing to do?

Upvotes: 0

Views: 854

Answers (1)

harrism
harrism

Reputation: 27809

NPP is included with the CUDA toolkit -- that is the compiler and libraries. (The SDK is the code examples.)

The CUDA Toolkit is typically installed into /usr/local/cuda, but if you don't have admin right, you can install it somewhere else. It definitely looks like you are using non-standard installation paths, so you will need to tell the SDK makefiles where to look.

If you look at the SDK's common.mk, you can see this line:

CUDA_INSTALL_PATH ?= /usr/local/cuda

So if you run

make CUDA_INSTALL_PATH=<my_path_to_cuda_toolkit>

it should be able to find NPP.

I think you could also make it an environment variable so you don't have to do it every time.

If that doesn't work, you might not have NPP, which would mean your CUDA toolkit version is too old.

Upvotes: 2

Related Questions