mirror of
https://github.com/void-linux/void-packages.git
synced 2025-04-22 17:17:03 +02:00
obs: fix build with gcc14 on i686
This commit is contained in:
parent
e69bc36b9a
commit
36e7c060d6
1 changed files with 40 additions and 0 deletions
40
srcpkgs/obs/patches/gcc14.patch
Normal file
40
srcpkgs/obs/patches/gcc14.patch
Normal file
|
@ -0,0 +1,40 @@
|
|||
From fd82ee5ac44ea59334efb80971e87edd26d03055 Mon Sep 17 00:00:00 2001
|
||||
From: oreo639 <oreo6391@gmail.com>
|
||||
Date: Wed, 16 Apr 2025 16:37:03 -0700
|
||||
Subject: [PATCH] libobs-opengl: Fix compile error on GCC 14+ and i686
|
||||
|
||||
Under the public gl_egl_query_dmabuf_modifiers_for_format, n_modifiers
|
||||
is defined as size_t, however in the static query_dmabuf_modifiers
|
||||
function, it is defined as EGLuint64KHR.
|
||||
|
||||
Since query_dmabuf_modifiers is only called by
|
||||
gl_egl_query_dmabuf_modifiers_for_format and n_modifiers is assigned
|
||||
from an EGLint, make it size_t for both.
|
||||
|
||||
This fixes building on i686 with gcc14.
|
||||
---
|
||||
libobs-opengl/gl-egl-common.c | 4 ++--
|
||||
1 file changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/libobs-opengl/gl-egl-common.c b/libobs-opengl/gl-egl-common.c
|
||||
index 10682b1a6e5408..f6abe59355832a 100644
|
||||
--- a/libobs-opengl/gl-egl-common.c
|
||||
+++ b/libobs-opengl/gl-egl-common.c
|
||||
@@ -349,7 +349,7 @@ bool gl_egl_query_dmabuf_capabilities(EGLDisplay egl_display, enum gs_dmabuf_fla
|
||||
}
|
||||
|
||||
static inline bool query_dmabuf_modifiers(EGLDisplay egl_display, EGLint drm_format, EGLuint64KHR **modifiers,
|
||||
- EGLuint64KHR *n_modifiers)
|
||||
+ size_t *n_modifiers)
|
||||
{
|
||||
EGLint max_modifiers;
|
||||
|
||||
@@ -376,7 +376,7 @@ static inline bool query_dmabuf_modifiers(EGLDisplay egl_display, EGLint drm_for
|
||||
*modifiers = modifier_list;
|
||||
}
|
||||
|
||||
- *n_modifiers = (EGLuint64KHR)max_modifiers;
|
||||
+ *n_modifiers = (size_t)max_modifiers;
|
||||
return true;
|
||||
}
|
||||
|
Loading…
Add table
Reference in a new issue