Skip to content

Commit

Permalink
CMake: Use FindWayland from ECM
Browse files Browse the repository at this point in the history
Fixes previously-broken FindWayland.cmake which had local modifications
that prevented PCSX2 from being compiled on OpenSUSE.
  • Loading branch information
stenzek committed Jul 6, 2023
1 parent 9763003 commit ecabadb
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 69 deletions.
1 change: 1 addition & 0 deletions .github/workflows/scripts/linux/install-packages-qt.sh
Expand Up @@ -37,6 +37,7 @@ declare -a BUILD_PACKAGES=(

# Packages - PCSX2
declare -a PCSX2_PACKAGES=(
"extra-cmake-modules"
"libaio-dev"
"libasound2-dev"
"libbz2-dev"
Expand Down
68 changes: 0 additions & 68 deletions cmake/FindWayland.cmake

This file was deleted.

4 changes: 3 additions & 1 deletion cmake/SearchForStuff.cmake
Expand Up @@ -82,7 +82,9 @@ else()
make_imported_target_if_missing(X11::X11 X11)

if(WAYLAND_API)
find_package(Wayland REQUIRED)
find_package(ECM REQUIRED NO_MODULE)
list(APPEND CMAKE_MODULE_PATH "${ECM_MODULE_PATH}")
find_package(Wayland REQUIRED Egl)
endif()

find_package(Libbacktrace)
Expand Down
4 changes: 4 additions & 0 deletions pcsx2/CMakeLists.txt
Expand Up @@ -649,6 +649,10 @@ if(USE_OPENGL)
if(WAYLAND_API)
list(APPEND pcsx2GSSources GS/Renderers/OpenGL/GLContextEGLWayland.cpp)
list(APPEND pcsx2GSHeaders GS/Renderers/OpenGL/GLContextEGLWayland.h)

# We load the Wayland libraries dynamically to avoid a runtime dependency.
# So, only add the headers, don't link.
target_include_directories(PCSX2_FLAGS INTERFACE ${Wayland_INCLUDE_DIRS})
endif()
endif()
endif()
Expand Down

0 comments on commit ecabadb

Please sign in to comment.