diff options
author | Zhigang Gong <zhigang.gong@intel.com> | 2014-11-13 13:37:15 +0800 |
---|---|---|
committer | Zhigang Gong <zhigang.gong@intel.com> | 2014-11-13 14:18:35 +0800 |
commit | 198344741a988849c0c77bb8de97062fcc54f1b9 (patch) | |
tree | 487c3735ce67ce26df138b7fe5481886beb86a08 /src | |
parent | b3109ad7c4d779a0649eb4123d7ee25b084a88b0 (diff) |
runtime: refine version handling.
Signed-off-by: Zhigang Gong <zhigang.gong@intel.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/OCLConfig.h.in | 1 | ||||
-rw-r--r-- | src/cl_platform_id.h | 4 |
2 files changed, 5 insertions, 0 deletions
diff --git a/src/OCLConfig.h.in b/src/OCLConfig.h.in index 8662584d..71de4b30 100644 --- a/src/OCLConfig.h.in +++ b/src/OCLConfig.h.in @@ -1,5 +1,6 @@ // the configured options and settings for LIBCL #define LIBCL_DRIVER_VERSION_MAJOR @LIBCL_DRIVER_VERSION_MAJOR@ #define LIBCL_DRIVER_VERSION_MINOR @LIBCL_DRIVER_VERSION_MINOR@ +#define LIBCL_DRIVER_VERSION_PATCH @LIBCL_DRIVER_VERSION_PATCH@ #define LIBCL_C_VERSION_MAJOR @LIBCL_C_VERSION_MAJOR@ #define LIBCL_C_VERSION_MINOR @LIBCL_C_VERSION_MINOR@ diff --git a/src/cl_platform_id.h b/src/cl_platform_id.h index 6c75bef1..7b78db13 100644 --- a/src/cl_platform_id.h +++ b/src/cl_platform_id.h @@ -69,7 +69,11 @@ extern cl_int cl_get_platform_info(cl_platform_id platform, #define BEIGNET_GIT_SHA1_STRING #endif +#ifdef LIBCL_DRIVER_VERSION_PATCH +#define LIBCL_DRIVER_VERSION_STRING _JOINT3(LIBCL_DRIVER_VERSION_MAJOR, LIBCL_DRIVER_VERSION_MINOR, LIBCL_DRIVER_VERSION_PATCH) +#else #define LIBCL_DRIVER_VERSION_STRING _JOINT(LIBCL_DRIVER_VERSION_MAJOR, LIBCL_DRIVER_VERSION_MINOR) +#endif #define LIBCL_VERSION_STRING "OpenCL " _JOINT(LIBCL_C_VERSION_MAJOR, LIBCL_C_VERSION_MINOR) " beignet " LIBCL_DRIVER_VERSION_STRING BEIGNET_GIT_SHA1_STRING #define LIBCL_C_VERSION_STRING "OpenCL C " _JOINT(LIBCL_C_VERSION_MAJOR, LIBCL_C_VERSION_MINOR) " beignet " LIBCL_DRIVER_VERSION_STRING BEIGNET_GIT_SHA1_STRING |