From https://github.com/xbmc/xbmc/pull/22291/commits/5449652abf0bb9dddd0d796de4120e60f19f89a5 From 5449652abf0bb9dddd0d796de4120e60f19f89a5 Mon Sep 17 00:00:00 2001 From: Alan Swanson Date: Mon, 19 Dec 2022 21:28:13 +0200 Subject: [PATCH] Work around Mesa eglchromium.h removal I have polished Alan's snippet to buildable state and tested on Kodi from Debian sid. Signed-off-by: Vasyl Gello --- cmake/modules/FindEGL.cmake | 6 ++++++ xbmc/windowing/X11/GLContextEGL.h | 4 ++++ 2 files changed, 10 insertions(+) diff --git a/cmake/modules/FindEGL.cmake b/cmake/modules/FindEGL.cmake index b00fe08a25f95..a68a8db901222 100644 --- a/cmake/modules/FindEGL.cmake +++ b/cmake/modules/FindEGL.cmake @@ -9,6 +9,7 @@ # EGL_INCLUDE_DIRS - the EGL include directory # EGL_LIBRARIES - the EGL libraries # EGL_DEFINITIONS - the EGL definitions +# HAVE_EGLEXTANGLE - if eglext_angle.h exists else use eglextchromium.h # # and the following imported targets:: # @@ -35,6 +36,11 @@ if(EGL_FOUND) set(EGL_LIBRARIES ${EGL_LIBRARY}) set(EGL_INCLUDE_DIRS ${EGL_INCLUDE_DIR}) set(EGL_DEFINITIONS -DHAS_EGL=1) + include(CheckIncludeFiles) + check_include_files("EGL/egl.h;EGL/eglext.h;EGL/eglext_angle.h" HAVE_EGLEXTANGLE) + if(HAVE_EGLEXTANGLE) + list(APPEND EGL_DEFINITIONS "-DHAVE_EGLEXTANGLE=1") + endif() if(NOT TARGET EGL::EGL) add_library(EGL::EGL UNKNOWN IMPORTED) diff --git a/xbmc/windowing/X11/GLContextEGL.h b/xbmc/windowing/X11/GLContextEGL.h index 99a6a9024e8c6..afea0b7c43eac 100644 --- a/xbmc/windowing/X11/GLContextEGL.h +++ b/xbmc/windowing/X11/GLContextEGL.h @@ -13,7 +13,11 @@ #include "threads/CriticalSection.h" #include +#ifdef HAVE_EGLEXTANGLE +#include +#else #include +#endif #include class CGLContextEGL : public CGLContext >
AgeCommit message (Expand)Author
2021-11-19daemon: Micro-optimize 'deletePath'....Ludovic Courtès
2020-12-08daemon: 'Agent' constructor takes a list of environment variables....Ludovic Courtès
2020-09-14daemon: Move 'Agent' to libutil....Ludovic Courtès
2020-06-27daemon: Recognize SHA3 and BLAKE2s....Ludovic Courtès
2020-06-27daemon: Remove OpenSSL hash compatibility wrappers....Ludovic Courtès
2020-06-27daemon: Map directly to gcrypt hash functions....Ludovic Courtès
2020-06-24nix: Tweak .gitignore files....Christopher Baines
2020-03-26daemon: Avoid kill -1 bug on the Hurd....Manolis Ragkousis
2020-01-12daemon: Account for deleted store files when deduplication is on....Ludovic Courtès
2019-11-29daemon: 'pathExists' uses 'statx' when available....Ludovic Courtès
2019-11-27daemon: 'deletePath' uses 'statx' when available....Ludovic Courtès
2019-08-30daemon: Don't reply on 'st_blocks'....Eelco Dolstra
2018-12-16daemon: Use unbranded phrases in comments and messages....Ludovic Courtès
2018-10-02daemon: Remove "case hack" for nars....Ludovic Courtès