summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPurushottam Choudhary <purushottam27.kumar@lge.com>2024-10-09 14:53:24 +0530
committerRichard Purdie <richard.purdie@linuxfoundation.org>2024-10-11 12:17:02 +0100
commita98139c8c3fefa3bf31b420123a08f1154cb9f7f (patch)
treeca9391234388404360aebf9c81c518c13ef4afc5
parenta24875260426249ead98b4ea3a1566b45f929905 (diff)
downloadpoky-a98139c8c3fefa3bf31b420123a08f1154cb9f7f.tar.gz
virglrenderer: Add patch to fix -int-conversion build issue
Fix int conversion related error during compilation as some of the platforms where EGLNativeDisplayType is an int instead of a pointer with GCC-14. (From OE-Core rev: f71f4936a273262343e34f278e6cfcc1e419aea3) Signed-off-by: Purushottam Choudhary <purushottam27.kumar@lge.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--meta/recipes-graphics/virglrenderer/virglrenderer/0001-vrend-Fix-int-conversion-fatal-build-error-with-GCC-.patch41
-rw-r--r--meta/recipes-graphics/virglrenderer/virglrenderer_1.0.1.bb1
2 files changed, 42 insertions, 0 deletions
diff --git a/meta/recipes-graphics/virglrenderer/virglrenderer/0001-vrend-Fix-int-conversion-fatal-build-error-with-GCC-.patch b/meta/recipes-graphics/virglrenderer/virglrenderer/0001-vrend-Fix-int-conversion-fatal-build-error-with-GCC-.patch
new file mode 100644
index 0000000000..9c49ee512a
--- /dev/null
+++ b/meta/recipes-graphics/virglrenderer/virglrenderer/0001-vrend-Fix-int-conversion-fatal-build-error-with-GCC-.patch
@@ -0,0 +1,41 @@
1From 464deabe4d1bfce6b8f414ab0945d9a62b66ddd4 Mon Sep 17 00:00:00 2001
2From: Purushottam Choudhary <purushottam27.kumar@lge.com>
3Date: Tue, 8 Oct 2024 11:47:21 +0530
4Subject: [PATCH] vrend: Fix int-conversion fatal build error with GCC-14
5
6Getting below error int conversion during compilation as one the
7platforms where EGLNativeDisplayType is an int instead of a pointer.
8
9| ../git/src/vrend_winsys_egl.c: In function 'virgl_egl_init':
10| ../git/src/vrend_winsys_egl.c:364:62: error: passing argument 2 of 'egl->funcs.epoxy_eglGetPlatformDisplay' makes pointer from
11| 364 | (EGLNativeDisplayType)egl->gbm->device, NULL);
12| | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
13| | |
14| | int
15| ../git/src/vrend_winsys_egl.c:364:62: note: expected 'void *' but argument is of type 'int'
16
17Upstream-Status: Backport [https://gitlab.freedesktop.org/virgl/virglrenderer/-/commit/464deabe4d1bfce6b8f414ab0945d9a62b66ddd4]
18
19Signed-off-by: Purushottam Choudhary <purushottam27.kumar@lge.com>
20Part-of: <https://gitlab.freedesktop.org/virgl/virglrenderer/-/merge_requests/1440>
21---
22
23 src/vrend_winsys_egl.c | 2 +-
24 1 file changed, 1 insertion(+), 1 deletion(-)
25
26diff --git a/src/vrend_winsys_egl.c b/src/vrend_winsys_egl.c
27index 9d9f410c..8750f6b2 100644
28--- a/src/vrend_winsys_egl.c
29+++ b/src/vrend_winsys_egl.c
30@@ -361,7 +361,7 @@ struct virgl_egl *virgl_egl_init(EGLNativeDisplayType display_id, bool surfacele
31 #ifdef ENABLE_GBM
32 else
33 egl->egl_display = egl->funcs.eglGetPlatformDisplay(EGL_PLATFORM_GBM_KHR,
34- (EGLNativeDisplayType)egl->gbm->device, NULL);
35+ (EGLNativeDisplayType*)egl->gbm->device, NULL);
36 #endif
37 } else {
38 #ifdef ENABLE_GBM
39--
402.34.1
41
diff --git a/meta/recipes-graphics/virglrenderer/virglrenderer_1.0.1.bb b/meta/recipes-graphics/virglrenderer/virglrenderer_1.0.1.bb
index 0501b0c59c..87f25a3461 100644
--- a/meta/recipes-graphics/virglrenderer/virglrenderer_1.0.1.bb
+++ b/meta/recipes-graphics/virglrenderer/virglrenderer_1.0.1.bb
@@ -12,6 +12,7 @@ DEPENDS = "libdrm libepoxy virtual/egl virtual/libgbm"
12SRCREV = "690680e5f0f952e22424fca1538c1b24457a0868" 12SRCREV = "690680e5f0f952e22424fca1538c1b24457a0868"
13SRC_URI = "git://gitlab.freedesktop.org/virgl/virglrenderer.git;branch=main;protocol=https \ 13SRC_URI = "git://gitlab.freedesktop.org/virgl/virglrenderer.git;branch=main;protocol=https \
14 file://0001-meson.build-use-python3-directly-for-python.patch \ 14 file://0001-meson.build-use-python3-directly-for-python.patch \
15 file://0001-vrend-Fix-int-conversion-fatal-build-error-with-GCC-.patch \
15 " 16 "
16 17
17S = "${WORKDIR}/git" 18S = "${WORKDIR}/git"