Unverified Commit 66a47345 authored by Axel Kohlmeyer's avatar Axel Kohlmeyer
Browse files

silence warnings from generic OpenCL header files (as seen on Fedora 31)

parent 8ac2da79
Loading
Loading
Loading
Loading
+8 −0
Original line number Diff line number Diff line
@@ -28,6 +28,14 @@
#include <vector>
#include <iostream>

/* We default to OpenCL 1.2 as target version for now as
 * there are known issues with OpenCL 2.0 and later.
 * This is also to silence warnings from generic OpenCL headers */

#if !defined(CL_TARGET_OPENCL_VERSION)
#define CL_TARGET_OPENCL_VERSION 120
#endif

#ifdef __APPLE__
#include <OpenCL/cl.h>
#include <OpenCL/cl_platform.h>
+8 −0
Original line number Diff line number Diff line
@@ -4,6 +4,14 @@
#include <cstdio>
#include <cassert>

/* We default to OpenCL 1.2 as target version for now as
 * there are known issues with OpenCL 2.0 and later.
 * This is also to silence warnings from generic OpenCL headers */

#if !defined(CL_TARGET_OPENCL_VERSION)
#define CL_TARGET_OPENCL_VERSION 120
#endif

#ifdef __APPLE__
#include <OpenCL/cl.h>
#else