Commit ae373e3d authored by Jan Vesely's avatar Jan Vesely Committed by Vinson Lee

cmake: Reintroduce version check to gbm_bo_map check

Fixes: 2217871a ("CMake: define GBM_BO_MAP only when symbol is found")
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=101358Signed-off-by: default avatarJan Vesely <jano.vesely@gmail.com>
Tested-by: Vinson Lee's avatarVinson Lee <vlee@freedesktop.org>
parent cc9928fd
......@@ -142,9 +142,11 @@ IF(${CMAKE_SYSTEM_NAME} MATCHES "Linux")
set(PIGLIT_HAS_GBM True)
add_definitions(-DPIGLIT_HAS_GBM)
set(CMAKE_REQUIRED_LIBRARIES ${CMAKE_REQUIRED_LIBRARIES} ${GBM_LIBRARIES})
CHECK_FUNCTION_EXISTS(gbm_bo_map PIGLIT_HAS_GBM_BO_MAP)
if (PIGLIT_HAS_GBM_BO_MAP)
add_definitions(-DPIGLIT_HAS_GBM_BO_MAP)
if (GBM_VERSION VERSION_EQUAL "12.1" OR GBM_VERSION VERSION_GREATER "12.1")
CHECK_FUNCTION_EXISTS(gbm_bo_map PIGLIT_HAS_GBM_BO_MAP)
if (PIGLIT_HAS_GBM_BO_MAP)
add_definitions(-DPIGLIT_HAS_GBM_BO_MAP)
endif()
endif()
endif(GBM_FOUND)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment