OpenCL (CUDA v5) and Visual Studio express 2010

Hi All,

Can someone help me to configure Visual Studio Express 2010 to compile/run my OpenCL applications? I’m using CUDA v5.0.

I’ve already set the include and lib directories in the Project Properties but I had no success.

Thanks in advance!

You might have included different path in the “Additional Include Directories” in the project properties.

For cuda v5.0 do ensure that your additional include direcories path is “\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v5.0\include” not “C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v5.0\include\CL”

Rest other configurations could be as it is referenced in other links on the internet.

As a matter of fact, you could add complete path to the opencl library in the Additional Library Dependencies i.e. “C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v5.0\lib\Win32”.
Also include the “opencl.lib” in the additional dependencies under Linker->Input in the project properties.

Note: All the above configuration was done on Windows 7 Enterprise Edition and Microsoft Visual C++ 2010 Express.