Skip to content

Commit

Permalink
Fixed unresolved xcb-dri3, forcing LD_PRELOAD workaround
Browse files Browse the repository at this point in the history
The appending of the library in the CMakeLists wasn't set correctly.
This fix will append the LIBRARIES in the CMake for XCB to ${libs} properly

Resolves:
- intel#178
- intel#175

Signed-off-by: Phoong, Stanley Cheong Kwan <[email protected]>
  • Loading branch information
leopck committed Apr 26, 2021
1 parent 6ab2418 commit 24cf5e1
Showing 1 changed file with 14 additions and 14 deletions.
28 changes: 14 additions & 14 deletions cmake/FindSinkDependencies.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ function(FindWayland libs)
pkg_check_modules(WAYLAND_CLIENT REQUIRED wayland-client)
pkg_check_modules(WAYLAND_CURSOR wayland-cursor)
if(WAYLAND_CLIENT_FOUND)
set(${libs} ${${libs}} ${WAYLAND_CLIENT_LIBRARIES} PARENT_SCOPE)
list(APPEND ${libs} ${WAYLAND_CLIENT_LIBRARIES})
include_directories (${WAYLAND_CLIENT_INCLUDE_DIRS})
pkg_check_modules (WESTON_4_0 weston>=3.0.0)
if (WESTON_4_0_FOUND)
Expand All @@ -11,7 +11,7 @@ function(FindWayland libs)
endif()

if(WAYLAND_CURSOR_FOUND)
set(${libs} ${${libs}} ${WAYLAND_CURSOR_LIBRARIES} PARENT_SCOPE)
list(APPEND ${libs} ${WAYLAND_CURSOR_LIBRARIES})
include_directories (${WAYLAND_CURSOR_INCLUDE_DIRS})
endif()
endfunction(FindWayland)
Expand All @@ -24,36 +24,36 @@ function(FindX11 libs)
pkg_check_modules(XRANDR xrandr)
pkg_check_modules(XRENDER xrender)
if(XCBDRI3_FOUND)
set(${libs} ${${libs}} ${XCBDRI3_LIBRARIES} PARENT_SCOPE)
include_directories (${XCBDRI3_INCLUDE_DIRS})
add_definitions(-DHAVE_XCBDRI3)
list(APPEND ${libs} ${XCBDRI3_LIBRARIES})
include_directories (${XCBDRI3_INCLUDE_DIRS})
add_definitions(-DHAVE_XCBDRI3)
endif()

if(XCBPRESENT_FOUND)
set(${libs} ${${libs}} ${XCBPRESENT_LIBRARIES} PARENT_SCOPE)
include_directories (${XCBPRESENT_INCLUDE_DIRS})
add_definitions(-DHAVE_XCBPRESENT)
list(APPEND ${libs} ${XCBPRESENT_LIBRARIES})
include_directories (${XCBPRESENT_INCLUDE_DIRS})
add_definitions(-DHAVE_XCBPRESENT)
endif()

if(X11_FOUND)
set(${libs} ${${libs}} ${X11_LIBRARIES} PARENT_SCOPE)
list(APPEND ${libs} ${X11_LIBRARIES})
include_directories (${X11_INCLUDE_DIRS})
endif()

if(XKB_FOUND)
set(${libs} ${${libs}} ${XKB_LIBRARIES} PARENT_SCOPE)
list(APPEND ${libs} ${XKB_LIBRARIES})
include_directories (${XKB_INCLUDE_DIRS})
add_definitions(-DHAVE_XKBLIB)
endif()

if(XRENDER_FOUND)
set(${libs} ${${libs}} ${XRENDER_LIBRARIES} PARENT_SCOPE)
list(APPEND ${libs} ${XRENDER_LIBRARIES})
include_directories (${XRENDER_INCLUDE_DIRS})
add_definitions(-DHAVE_XRENDER)
endif()

if(XRANDR_FOUND)
set(${libs} ${${libs}} ${XRANDR_LIBRARIES} PARENT_SCOPE)
list(APPEND ${libs} ${XRANDR_LIBRARIES})
include_directories (${XRANDR_INCLUDE_DIRS})
add_definitions(-DHAVE_XRANDR)
endif()
Expand All @@ -62,15 +62,15 @@ endfunction(FindX11)
function(FindEGL libs)
pkg_check_modules(EGL REQUIRED egl)
if(EGL_FOUND)
set(${libs} ${${libs}} ${EGL_LIBRARIES} PARENT_SCOPE)
list(APPEND ${libs} ${EGL_LIBRARIES})
include_directories(${EGL_INCLUDE_DIRS})
endif()
endfunction(FindEGL)

function(FindEGLWayland libs)
pkg_check_modules(WAYLAND_EGL REQUIRED wayland-egl)
if(WAYLAND_EGL_FOUND)
set(${libs} ${${libs}} ${WAYLAND_EGL_LIBRARIES} PARENT_SCOPE)
list(APPEND ${libs} ${WAYLAND_EGL_LIBRARIES})
include_directories(${WAYLAND_EGL_INCLUDE_DIRS})
endif()
endfunction(FindEGLWayland)

0 comments on commit 24cf5e1

Please sign in to comment.