Skip to content

Commit

Permalink
Build error fix for when CL_USE_SHIPPED_EXT=False and CL/cl_ext.h doe…
Browse files Browse the repository at this point in the history
…sn't define cl_device_topology_amd struct.
  • Loading branch information
Shane-J-Latham committed Jun 13, 2016
1 parent b993286 commit 21b471a
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions src/c_wrapper/pyopencl_ext.h
Expand Up @@ -16,6 +16,16 @@
#include <CL/cl.h>
#include <CL/cl_ext.h>

#ifndef CL_DEVICE_TOPOLOGY_TYPE_PCIE_AMD
#define CL_DEVICE_TOPOLOGY_TYPE_PCIE_AMD 1

typedef union
{
struct { cl_uint type; cl_uint data[5]; } raw;
struct { cl_uint type; cl_char unused[17]; cl_char bus; cl_char device; cl_char function; } pcie;
} cl_device_topology_amd;
#endif

#endif

#endif
Expand Down

0 comments on commit 21b471a

Please sign in to comment.