I am trying to compile this. I am using the AMD SDK. I am using the header files that come with the aforementioned SDK and they are located in:
C:\Program Files (x86)\AMD APP\include\CL
The tutorial states:
Header files Just like any other external API used in C++, you must include a header file when using the OpenCLâ„¢ API. Usually, this is in the directory CL within the primary include directory. For the C++ bindings we have (replace the straight C API with cl.h):
I found that last bit a little confusing. I am using both .h and .hpp
#include <CL/cl.h> when this is used it will compile the checkErr function
#include <CL/cl.hpp> when this is used it gives me access to the cl namespace
When I try to compile this code it fails with:
'clUnloadCompiler': was declared deprecated

ADDITIONAL DETAILS (after removing #include <CL/c.h>)
It now gives the following list of errors:

error C4996: Error 2 error LNK2019: unresolved external symbol _clReleaseCommandQueue@4 referenced in function "public: static int __cdecl cl::detail::ReferenceHandler<struct _cl_command_queue *>::release(struct _cl_command_queue *)" (?release@?$ReferenceHandler@PAU_cl_command_queue@@@detail@cl@@SAHPAU_cl_command_queue@@@Z)
error LNK2019: unresolved external symbol _clReleaseContext@4 referenced in function "public: static int __cdecl cl::detail::ReferenceHandler<struct _cl_context *>::release(struct _cl_context *)" (?release@?$ReferenceHandler@PAU_cl_context@@@detail@cl@@SAHPAU_cl_context@@@Z)
In properties for my project I have:
- added C:\Program Files (x86)\AMD APP\include\ as an additional include directory
- added C:\Program Files (x86)\AMD APP\lib\x86_64 as an additional library directory
- added OpenCL.lib as an additional dependency
The errors I listed happen regardless of whether or not I take the last two steps. That is, the last two do not seem to be helping or harming anything
#include <CL/cl.h>? - Markku K.