OpenCL is not part of Android, so you cannot find cl.h.
Download necessary CL header files from here: https://www.khronos.org/registry/cl/
Download the cl.h with the correct version (same as the CL version you are using, for example, CL 1.1).
Include the header files in your OpenCL program, then you are good to go.
Edited 4/18/2015:
To include the OpenCL header files, you can do the following:
#ifdef __APPLE__
#include <OpenCL/opencl.h>
#else
#include <CL/opencl.h>
#endif
But if you program is a purely CL code (without CL-GL interoperability), simply including CL/cl.h should also work:
#include <CL/cl.h>
After doing this, you should add the folder that contains CL folder into the include path in your makefile. (The following assumes that PATH_TO_CL_FOLDER is your CL folder)
For those who use Android.mk
If you work with Application.mk and Android.mk, and build your native library using traditional ndk-build
way, you should add the path to CL directory into the LOCAL_C_INCLUDES variable
in Android.mk).
LOCAL_C_INCLUDES += PATH_TO_CL_FOLDER
For those who work with Gradle in Android Studio (This is what you need)
Edit build.gradle, add your include path in the cFlags field as shown below:
android {
defaultConfig {
ndk {
moduleName "yourlib"
stl "stlport_static"
ldLibs "log", "z"
cFlags "-IPATH_TO_CL_FOLDER"
}
...
}
...
}