GLContext: Wayland support

This commit is contained in:
Connor McLaughlin
2020-07-07 21:40:55 +10:00
parent eab70546c8
commit 4ce5f7e802
5 changed files with 91 additions and 2 deletions

View File

@ -149,7 +149,7 @@ if(USE_EGL)
endif()
endif()
if(SUPPORTS_X11)
if(USE_X11)
target_sources(common PRIVATE
gl/context_glx.cpp
gl/context_glx.h
@ -157,6 +157,15 @@ if(SUPPORTS_X11)
target_compile_definitions(common PRIVATE "-DUSE_GLX=1")
endif()
if(USE_WAYLAND)
target_sources(common PRIVATE
gl/context_egl_wayland.cpp
gl/context_egl_wayland.h
)
target_compile_definitions(common PRIVATE "-DUSE_WAYLAND=1")
target_link_libraries(common PRIVATE Wayland::Egl)
endif()
if(APPLE)
target_sources(common PRIVATE
gl/context_agl.mm