From 06365d9792ce6f623eb8c2c16c136b37ad930297 Mon Sep 17 00:00:00 2001 From: pradeep Date: Tue, 26 Jan 2021 10:27:13 +0530 Subject: [PATCH 1/2] Fix OpenCL examples warnings for newer OpenCL headers --- examples/opencl/cl_helpers.h | 1 + 1 file changed, 1 insertion(+) diff --git a/examples/opencl/cl_helpers.h b/examples/opencl/cl_helpers.h index b78e43e7..9ae3b478 100644 --- a/examples/opencl/cl_helpers.h +++ b/examples/opencl/cl_helpers.h @@ -11,6 +11,7 @@ #define CL_HPP_ENABLE_EXCEPTIONS #define CL_HPP_MINIMUM_OPENCL_VERSION 120 #define CL_HPP_TARGET_OPENCL_VERSION 120 +#define CL_TARGET_OPENCL_VERSION 120 #if defined(__GNUC__) #pragma GCC diagnostic push From a27c74f1422fcc9f10468dbe4e5b0d323a904dd1 Mon Sep 17 00:00:00 2001 From: pradeep Date: Tue, 26 Jan 2021 10:31:15 +0530 Subject: [PATCH 2/2] Remove unncessary X11 linage in OpenCL examples --- examples/CMakeLists.txt | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) diff --git a/examples/CMakeLists.txt b/examples/CMakeLists.txt index 8146619a..7be2067a 100644 --- a/examples/CMakeLists.txt +++ b/examples/CMakeLists.txt @@ -22,17 +22,6 @@ mark_as_advanced( CUDA_rt_LIBRARY CMAKE_CUDA_HOST_COMPILER) -if(APPLE) - find_package(X11 REQUIRED) - if(X11_FOUND AND NOT TARGET X11::x11) - add_library(X11::x11 UNKNOWN IMPORTED) - set_target_properties(X11::x11 PROPERTIES - IMPORTED_LINK_INTERFACE_LANGUAGE "C" - IMPORTED_LOCATION "${X11_X11_LIB}" - INTEFACE_INCLUDE_DIRECTORIES "${X11_INCLUDE_DIR}") - endif() -endif() - include(CMakeParseArguments) include(CMakeDependentOption) include(InternalUtils) @@ -100,8 +89,7 @@ function(add_example target_name source backend) target_link_libraries(${target} OSCompileFlags Forge::forge - ${arg_LIBRARIES} - $<$:X11::x11>) + ${arg_LIBRARIES}) endfunction() add_subdirectory(cpu)