OpenCL example makefile not found for libshrutil_x86 build

Hi all,

Running Ubuntu 12.04, CUDA 5.0
Attempting to build one of the OpenCL examples I manually downloaded.

I tried to build in the OpenCL dir but get these errors:

dlowell@rnd03:~/NVSDK/OpenCL$ make
make[1]: Entering directory `/home/dlowell/NVSDK/OpenCL/common'
cc1plus: warning: command line option ‘-Wimplicit’ is valid for C/ObjC but not for C++ [enabled by default]
ar: creating ../..//OpenCL//common//lib/liboclUtil_x86_64.a
a - obj/release/oclUtils.cpp.o
make[1]: Leaving directory `/home/dlowell/NVSDK/OpenCL/common'
make[1]: Entering directory `/home/dlowell/NVSDK/shared'
make[1]: *** No targets specified and no makefile found.  Stop.
make[1]: Leaving directory `/home/dlowell/NVSDK/shared'
make: *** [shared/] Error 2

NVSDK is my replacement name for the annoying “NVIDIA GPU Computing SDK”
Using relative paths everything should take care if itself. I also tried this under the original naming. I can’t really move forward to try building the examples since they require this particular library.





Something seems to be missing. Anyone have a idea?


hi redratio1,

I too was having this problem, I thought it was my fault but actually I think the samples are wrong. I think there’s a missing makefile, due to NVIDIA removing the openCL samples from the 5.0 SDK, and making you download them one by one.

Fix: you must download the sdk 4.2 kit, which has all the samples zipped. Linux link:

and mirror

Then the makefile in /OpenCL/ completes properly (at least for me on ubuntu 12.04).

Credit & more about it on this blog asking for nvidia to start supporting opencl properly again

For OpenCL I needed to download whole CUDA SDK 4.2.9 as sschaetz’s git does not provide shrUtils.h and CUDA 5.0 does not contain ocl at all :(
Explanation in link above.
It complied and run on Fedora 18 x64 and Fedora 16 x64 just fine.
OCL examples here for your convenience :

yum -y install gcc libXmu-devel