找到OpenCL¶
在 3.1 版本加入.
寻找开放计算语言 (OpenCL)
在 3.10 版本加入: 检测 OpenCL 2.1 和 2.2。
进口目标¶
在 3.7 版本加入.
这个模块定义:prop_tgt:IMPORTED 目标``OpenCL::OpenCL``,如果已经找到 OpenCL。
结果变量¶
该模块定义了以下变量
OpenCL_FOUND - True if OpenCL was found
OpenCL_INCLUDE_DIRS - include directories for OpenCL
OpenCL_LIBRARIES - link against this library to use OpenCL
OpenCL_VERSION_STRING - Highest supported OpenCL version (eg. 1.2)
OpenCL_VERSION_MAJOR - The major version of the OpenCL implementation
OpenCL_VERSION_MINOR - The minor version of the OpenCL implementation
该模块还将定义两个缓存变量
OpenCL_INCLUDE_DIR - the OpenCL include directory
OpenCL_LIBRARY - the path to the OpenCL library