[Beignet] [PATCH] CMAKE: Use DRM_INTEL_LIBDIR for CHECK_LIBRARY_EXISTS path
Xiuli Pan
xiuli.pan at intel.com
Thu Jun 30 06:48:38 UTC 2016
From: Pan Xiuli <xiuli.pan at intel.com>
We check libdrm-intel with pkg-config, but CHECK_LIBRARY_EXISTS may
search lib in different path, so add the path we will use for it.
Signed-off-by: Pan Xiuli <xiuli.pan at intel.com>
---
CMakeLists.txt | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/CMakeLists.txt b/CMakeLists.txt
index fae3e88..569d109 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -135,19 +135,19 @@ pkg_check_modules(DRM_INTEL libdrm_intel>=2.4.52)
IF(DRM_INTEL_FOUND)
INCLUDE_DIRECTORIES(${DRM_INTEL_INCLUDE_DIRS})
MESSAGE(STATUS "Looking for DRM Intel - found at ${DRM_INTEL_PREFIX} ${DRM_INTEL_VERSION}")
- CHECK_LIBRARY_EXISTS(drm_intel "drm_intel_bo_alloc_userptr" "" HAVE_DRM_INTEL_USERPTR)
+ CHECK_LIBRARY_EXISTS(drm_intel "drm_intel_bo_alloc_userptr" ${DRM_INTEL_LIBDIR} HAVE_DRM_INTEL_USERPTR)
IF(HAVE_DRM_INTEL_USERPTR)
MESSAGE(STATUS "Enable userptr support")
ELSE(HAVE_DRM_INTEL_USERPTR)
MESSAGE(STATUS "Disable userptr support")
ENDIF(HAVE_DRM_INTEL_USERPTR)
- CHECK_LIBRARY_EXISTS(drm_intel "drm_intel_get_eu_total" "" HAVE_DRM_INTEL_EU_TOTAL)
+ CHECK_LIBRARY_EXISTS(drm_intel "drm_intel_get_eu_total" ${DRM_INTEL_LIBDIR} HAVE_DRM_INTEL_EU_TOTAL)
IF(HAVE_DRM_INTEL_EU_TOTAL)
MESSAGE(STATUS "Enable EU total query support")
ELSE(HAVE_DRM_INTEL_EU_TOTAL)
MESSAGE(STATUS "Disable EU total query support")
ENDIF(HAVE_DRM_INTEL_EU_TOTAL)
- CHECK_LIBRARY_EXISTS(drm_intel "drm_intel_get_subslice_total" "" HAVE_DRM_INTEL_SUBSLICE_TOTAL)
+ CHECK_LIBRARY_EXISTS(drm_intel "drm_intel_get_subslice_total" ${DRM_INTEL_LIBDIR} HAVE_DRM_INTEL_SUBSLICE_TOTAL)
IF(HAVE_DRM_INTEL_SUBSLICE_TOTAL)
MESSAGE(STATUS "Enable subslice total query support")
ELSE(HAVE_DRM_INTEL_SUBSLICE_TOTAL)
--
2.5.0
More information about the Beignet
mailing list