diff --git a/recipes-graphics/wayland/egl-wayland/0001-wayland-eglsurface-Change-type-of-timout-from-EGLint.patch b/recipes-graphics/wayland/egl-wayland/0001-wayland-eglsurface-Change-type-of-timout-from-EGLint.patch new file mode 100644 index 00000000..cdd24c00 --- /dev/null +++ b/recipes-graphics/wayland/egl-wayland/0001-wayland-eglsurface-Change-type-of-timout-from-EGLint.patch @@ -0,0 +1,40 @@ +From 49e4da8890560c949a4352397fdd083b7175b1b6 Mon Sep 17 00:00:00 2001 +From: Khem Raj +Date: Wed, 12 Jun 2024 17:32:06 -0700 +Subject: [PATCH] wayland-eglsurface: Change type of timout from EGLint -> + EGLTime + +This seems to be the appropriate type representation for +timeout, moreover it also fixes an error with newer compilers where +it complains about type mismatch between EGLint and EGL_FOREVER because +EGL_FOREVER is defined as 0xFFFFFFFFFFFFFFFFull which is unsinged long +long. + +Fixes +| ../git/src/wayland-eglsurface.c:1591:62: error: implicit conversion from 'unsigned long long' to 'EGLint' (aka 'int') changes value from 18446744073709551615 to -1 [-Werror,] +| 1591 | EGLint timeout = surface->wlSyncobjSurf ? EGL_FOREVER : 0; +| | ~~~~~~~ ^~~~~~~~~~~ +| /mnt/b/yoe/master/build/tmp/work/armv8a-yoe-linux/egl-wayland/1.1.13+git/recipe-sysroot/usr/include/EGL/egl.h:293:43: note: expanded from macro 'EGL_FOREVER' +| 293 | #define EGL_FOREVER 0xFFFFFFFFFFFFFFFFull +| | ^~~~~~~~~~~~~~~~~~~~~ +| 1 error generated. + +Upstream-Status: Submitted [https://github.com/NVIDIA/egl-wayland/pull/112] +Signed-off-by: Khem Raj +--- + src/wayland-eglsurface.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/wayland-eglsurface.c b/src/wayland-eglsurface.c +index 0c28a4f..4932217 100644 +--- a/src/wayland-eglsurface.c ++++ b/src/wayland-eglsurface.c +@@ -1588,7 +1588,7 @@ EGLint wlEglHandleImageStreamEvents(WlEglSurface *surface) + EGLAttrib aux; + EGLenum event; + EGLint err = EGL_SUCCESS; +- EGLint timeout = surface->wlSyncobjSurf ? EGL_FOREVER : 0; ++ EGLTime timeout = surface->wlSyncobjSurf ? EGL_FOREVER : 0; + + if (surface->ctx.wlStreamResource) { + /* Not a local stream */ diff --git a/recipes-graphics/wayland/egl-wayland_git.bb b/recipes-graphics/wayland/egl-wayland_git.bb index 92a9dec5..75bb60da 100644 --- a/recipes-graphics/wayland/egl-wayland_git.bb +++ b/recipes-graphics/wayland/egl-wayland_git.bb @@ -12,6 +12,7 @@ PV = "1.1.13+git" SRC_URI += " \ file://0001-Fix-wayland-eglstream-protocols-pc-file.patch \ + file://0001-wayland-eglsurface-Change-type-of-timout-from-EGLint.patch \ file://nvidia_wayland.json \ "