Compare commits

...

10 Commits

Author SHA1 Message Date
Olivier Fourdan 6d41932d43 Install 15_nvidia_gbm.json 2023-05-18 10:59:37 +00:00
Dave Airlie 9bf68d8c6a Update to egl-wayland 1.1.9 like Fedora
Resolves: rhbz#2015854
2022-01-25 11:01:20 +10:00
Mohan Boddu f9deb88571 Rebuilt for IMA sigs, glibc 2.34, aarch64 flags
Related: rhbz#1991688
Signed-off-by: Mohan Boddu <mboddu@redhat.com>
2021-08-09 19:54:17 +00:00
Olivier Fourdan 8dc9a74665 Rebuild for annobin-9.79
Related: rhbz#1975875
2021-07-07 13:58:44 +02:00
Olivier Fourdan 6c75e07509 Update to 1.1.7
Resolves: rhbz#1975875
2021-07-01 16:09:34 +02:00
Tomas Pelka 35cfabb7cb enabling gating for el9 2021-06-16 13:17:28 +02:00
Mohan Boddu 544cbc3725 - Rebuilt for RHEL 9 BETA on Apr 15th 2021. Related: rhbz#1947937
Signed-off-by: Mohan Boddu <mboddu@redhat.com>
2021-04-15 23:12:05 +00:00
DistroBaker 28ad762c07 Merged update from upstream sources
This is an automated DistroBaker update from upstream sources.
If you do not know what this is about or would like to opt out,
contact the OSCI team.

Source: https://src.fedoraproject.org/rpms/egl-wayland.git#d5066604401a6d5a12644227afe3c99f9e29b9a8
2021-02-03 13:17:30 +01:00
DistroBaker d597017f1b Merged update from upstream sources
This is an automated DistroBaker update from upstream sources.
If you do not know what this is about or would like to opt out,
contact the OSCI team.

Source: https://src.fedoraproject.org/rpms/egl-wayland.git#a28e74537689c4b4903879611df7f2d95810e22d
2021-01-07 14:34:23 +00:00
Petr Šabata c41dbd3400 RHEL 9.0.0 Alpha bootstrap
The content of this branch was automatically imported from Fedora ELN
with the following as its source:
https://src.fedoraproject.org/rpms/egl-wayland#8fb8070207391ccc14e42b6069508f3ab2b0146c
2020-10-14 23:59:16 +02:00
12 changed files with 808 additions and 0 deletions

1
.egl-wayland.metadata Normal file
View File

@ -0,0 +1 @@
69912f237f1de25f530cbdcdb57164f265bdaa4b egl-wayland-1.1.9.tar.gz

19
.gitignore vendored
View File

@ -0,0 +1,19 @@
/egl-wayland-743d702fac0feb02d52ff34deadecb32284f18ea.tar.gz
/egl-wayland-05eb0003bf9d17a16452f10aae13e66f4cfd6cda.tar.gz
/egl-wayland-582fbf371105d0cc082ff804481f6d28cf4bc8f0.tar.gz
/egl-wayland-818b6135ad6883afbaec83f5da0d3204238416a7.tar.gz
/egl-wayland-1f4b1fde684595fe28e250b7429e028a7bb7d40d.tar.gz
/egl-wayland-b283689e369116aaf41ffac70d4eeef19ce133a4.tar.gz
/egl-wayland-6f5f7d0d50287b810e9dec4718d3cf995fed809a.tar.gz
/egl-wayland-4ab087336614770c524cc51d8f9befa719d80cc9.tar.gz
/egl-wayland-395ce9f609fbf66f6cab622aec3ded663e089f84.tar.gz
/egl-wayland-1676d1d2bfe646fb3ecbba29a85db529dd399493.tar.gz
/egl-wayland-0eb29d4a84788b2abb3642ec2d3ccec0b0befe36.tar.gz
/egl-wayland-1.1.1.tar.gz
/egl-wayland-1.1.2.tar.gz
/egl-wayland-1.1.3.tar.gz
/egl-wayland-1.1.4.tar.gz
/egl-wayland-1.1.5.tar.gz
/egl-wayland-1.1.6.tar.gz
/egl-wayland-1.1.7.tar.gz
/egl-wayland-1.1.9.tar.gz

6
10_nvidia_wayland.json Normal file
View File

@ -0,0 +1,6 @@
{
"file_format_version" : "1.0.0",
"ICD" : {
"library_path" : "libnvidia-egl-wayland.so.1"
}
}

6
15_nvidia_gbm.json Normal file
View File

@ -0,0 +1,6 @@
{
"file_format_version" : "1.0.0",
"ICD" : {
"library_path" : "libnvidia-egl-gbm.so.1"
}
}

View File

@ -0,0 +1,180 @@
From 582b2d345abaa0e313cf16c902e602084ea59551 Mon Sep 17 00:00:00 2001
From: Erik Kurzinger <ekurzinger@nvidia.com>
Date: Tue, 23 Nov 2021 14:15:14 -0500
Subject: [PATCH] egl-wayland: retrieve DRM device name before acquiring API
lock
wlEglBindDisplaysHook acquires the external API lock before calling
wl_eglstream_display_bind, which in turn calls wl_drm_display_bind. That
function calls back into EGL to query the DRM device associated with the
given EGLDisplay.
Normally this is not a problem since the EGLDisplay passed to
eglBindWaylandDisplayWL will be an internal EGL_PLATFORM_DEVICE handle.
However, some applications, notably anything WebKit-based, will instead
pass in an external EGL_PLATFORM_WAYLAND handle. This means that the
eglQueryDisplayAttrib call by wl_drm_display_bind will require EGL to
call back into the egl-wayland library to look up the internal handle.
This is done by wlEglGetInternalHandleExport, which will attempt to
acquire the external API lock a second time, which will fail.
To avoid this, add a new function to wayland-drm.c which will retrieve
the DRM device name for the given EGLDisplay. wlEglBindDisplaysHook will
call this *before* acquiring the external API lock, and then pass it to
wl_drm_display_bind via wl_eglstream_display_bind so it can be saved in
the wl_eglstream_display struct.
---
include/wayland-drm.h | 7 ++++++-
include/wayland-eglstream-server.h | 3 ++-
src/wayland-drm.c | 33 +++++++++++++++---------------
src/wayland-egldisplay.c | 8 +++++---
src/wayland-eglstream-server.c | 5 +++--
5 files changed, 32 insertions(+), 24 deletions(-)
diff --git a/include/wayland-drm.h b/include/wayland-drm.h
index be363c6..84d0f11 100644
--- a/include/wayland-drm.h
+++ b/include/wayland-drm.h
@@ -23,9 +23,14 @@
#ifndef WAYLAND_DRM_H
#define WAYLAND_DRM_H
+extern const char *
+wl_drm_get_dev_name(const WlEglPlatformData *data,
+ EGLDisplay dpy);
+
extern EGLBoolean
wl_drm_display_bind(struct wl_display *display,
- struct wl_eglstream_display *wlStreamDpy);
+ struct wl_eglstream_display *wlStreamDpy,
+ const char *dev_name);
extern void
wl_drm_display_unbind(struct wl_eglstream_display *wlStreamDpy);
diff --git a/include/wayland-eglstream-server.h b/include/wayland-eglstream-server.h
index 76e772c..0f7d477 100644
--- a/include/wayland-eglstream-server.h
+++ b/include/wayland-eglstream-server.h
@@ -49,7 +49,8 @@ EGLBoolean
wl_eglstream_display_bind(WlEglPlatformData *data,
struct wl_display *wlDisplay,
EGLDisplay eglDisplay,
- const char *exts);
+ const char *exts,
+ const char *dev_name);
/*
* wl_eglstream_display_unbind()
diff --git a/src/wayland-drm.c b/src/wayland-drm.c
index aa6de23..a08d82f 100644
--- a/src/wayland-drm.c
+++ b/src/wayland-drm.c
@@ -152,37 +152,36 @@ bind(struct wl_client *client, void *data, uint32_t version, uint32_t id)
wl_resource_post_event(resource, WL_DRM_CAPABILITIES, 0);
}
-EGLBoolean
-wl_drm_display_bind(struct wl_display *display,
- struct wl_eglstream_display *wlStreamDpy)
+const char *
+wl_drm_get_dev_name(const WlEglPlatformData *data,
+ EGLDisplay dpy)
{
- EGLDisplay dpy = wlStreamDpy->eglDisplay;
EGLDeviceEXT egl_dev;
const char *dev_exts;
- const char *dev_name;
- if (!wlStreamDpy->data->egl.queryDisplayAttrib(dpy,
- EGL_DEVICE_EXT,
- (EGLAttribKHR*)&egl_dev)) {
- return EGL_FALSE;
+ if (!data->egl.queryDisplayAttrib(dpy, EGL_DEVICE_EXT,
+ (EGLAttribKHR*)&egl_dev)) {
+ return NULL;
}
-
- dev_exts = wlStreamDpy->data->egl.queryDeviceString(egl_dev,
- EGL_EXTENSIONS);
+ dev_exts = data->egl.queryDeviceString(egl_dev, EGL_EXTENSIONS);
if (!dev_exts) {
- return EGL_FALSE;
+ return NULL;
}
if (!wlEglFindExtension("EGL_EXT_device_drm_render_node", dev_exts)) {
- return EGL_FALSE;
+ return NULL;
}
- dev_name =
- wlStreamDpy->data->egl.queryDeviceString(egl_dev,
- EGL_DRM_RENDER_NODE_FILE_EXT);
+ return data->egl.queryDeviceString(egl_dev, EGL_DRM_RENDER_NODE_FILE_EXT);
+}
+EGLBoolean
+wl_drm_display_bind(struct wl_display *display,
+ struct wl_eglstream_display *wlStreamDpy,
+ const char *dev_name)
+{
if (!dev_name) {
return EGL_FALSE;
}
diff --git a/src/wayland-egldisplay.c b/src/wayland-egldisplay.c
index 8b7394a..d285bf7 100644
--- a/src/wayland-egldisplay.c
+++ b/src/wayland-egldisplay.c
@@ -30,6 +30,7 @@
#include "wayland-eglhandle.h"
#include "wayland-eglutils.h"
#include "wayland-drm-client-protocol.h"
+#include "wayland-drm.h"
#include <string.h>
#include <stdlib.h>
#include <assert.h>
@@ -70,15 +71,16 @@ EGLBoolean wlEglIsValidNativeDisplayExport(void *data, void *nativeDpy)
EGLBoolean wlEglBindDisplaysHook(void *data, EGLDisplay dpy, void *nativeDpy)
{
- /* Retrieve extension string before taking external API lock */
- const char *exts = ((WlEglPlatformData *)data)->egl.queryString(dpy, EGL_EXTENSIONS);
+ /* Retrieve extension string and device name before taking external API lock */
+ const char *exts = ((WlEglPlatformData *)data)->egl.queryString(dpy, EGL_EXTENSIONS),
+ *dev_name = wl_drm_get_dev_name(data, dpy);
EGLBoolean res = EGL_FALSE;
wlExternalApiLock();
res = wl_eglstream_display_bind((WlEglPlatformData *)data,
(struct wl_display *)nativeDpy,
- dpy, exts);
+ dpy, exts, dev_name);
wlExternalApiUnlock();
diff --git a/src/wayland-eglstream-server.c b/src/wayland-eglstream-server.c
index b1baa08..1dfd7ce 100644
--- a/src/wayland-eglstream-server.c
+++ b/src/wayland-eglstream-server.c
@@ -289,7 +289,8 @@ EGLBoolean
wl_eglstream_display_bind(WlEglPlatformData *data,
struct wl_display *wlDisplay,
EGLDisplay eglDisplay,
- const char *exts)
+ const char *exts,
+ const char *dev_name)
{
struct wl_eglstream_display *wlStreamDpy = NULL;
char *env = NULL;
@@ -355,7 +356,7 @@ wl_eglstream_display_bind(WlEglPlatformData *data,
wl_eglstream_display_global_bind);
/* Failure is not fatal */
- wl_drm_display_bind(wlDisplay, wlStreamDpy);
+ wl_drm_display_bind(wlDisplay, wlStreamDpy, dev_name);
wl_list_insert(&wlStreamDpyList, &wlStreamDpy->link);

View File

@ -0,0 +1,36 @@
From 9558ec02d0f7bbf30dc1f9ee4c0b06c9b0c49afe Mon Sep 17 00:00:00 2001
From: Erik Kurzinger <ekurzinger@nvidia.com>
Date: Fri, 14 Aug 2020 07:27:58 -0700
Subject: [PATCH] suspend lock in eglBindWaylandDisplayWL
When binding an external EGL display to a Wayland display, core EGL will
need to translate the external handle to an internal handle before
performing any API calls. This may occur, for example, when running a
nested Wayland compositor where the EGL display will be using
EGL_PLATFORM_WAYLAND as opposed to EGL_PLATFORM_DEVICE. Translating this
handle involves calling wlEglGetInternalHandleExport, which attempts to
acquire the external API lock. However, during eglBindWaylandDisplayWL this
lock is already held. As a result, when wl_eglstream_display_bind calls
eglQueryString to retrieve the extension string, this lock acquisition will
fail causing a crash.
To fix this, wl_eglstream_display_bind should temporarily suspend the API
lock before calling eglQueryString.
---
src/wayland-eglstream-server.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/src/wayland-eglstream-server.c b/src/wayland-eglstream-server.c
index c37f8e6..331ad32 100644
--- a/src/wayland-eglstream-server.c
+++ b/src/wayland-eglstream-server.c
@@ -308,7 +308,9 @@ wl_eglstream_display_bind(WlEglPlatformData *data,
wlStreamDpy->eglDisplay = eglDisplay;
wlStreamDpy->caps_override = 0;
+ wlExternalApiUnlock();
exts = data->egl.queryString(eglDisplay, EGL_EXTENSIONS);
+ wlExternalApiLock();
#define CACHE_EXT(_PREFIX_, _NAME_) \
wlStreamDpy->exts._NAME_ = \

View File

@ -0,0 +1,24 @@
From 9c9c4c684983f7b0821f516f8821118170a785ea Mon Sep 17 00:00:00 2001
From: Erik Kurzinger <ekurzinger@nvidia.com>
Date: Fri, 14 Aug 2020 14:17:25 -0700
Subject: [PATCH] include wayland-thread.h from wayland-eglstream-server.c
The previous commit referenced functions declared in wayland-thread.h
from wayland-eglstream-server.c, but neglected to add the required
include directive.
---
src/wayland-eglstream-server.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/src/wayland-eglstream-server.c b/src/wayland-eglstream-server.c
index 331ad32..a62d7db 100644
--- a/src/wayland-eglstream-server.c
+++ b/src/wayland-eglstream-server.c
@@ -40,6 +40,7 @@
#include "wayland-eglstream.h"
#include "wayland-eglswap.h"
#include "wayland-eglutils.h"
+#include "wayland-thread.h"
#define MASK(_VAL_) (1 << (_VAL_))

View File

@ -0,0 +1,268 @@
From d4937adc5cd04ac7df98fc5616e40319fb52fdee Mon Sep 17 00:00:00 2001
From: Austin Shafer <ashafer@nvidia.com>
Date: Wed, 27 Oct 2021 06:37:07 -0400
Subject: [PATCH] wayland: Fail eglGetDisplay if wl_drm is not available
This patch does two things:
- checks if wl_drm is in use on the server, and uses it to get the name
of the drm device the compositor is driving.
- Find an EGLDevice that matches the path returned by wl_drm.
If wl_drm and the needed extensions are not present, or if a matching
EGLDevice is not found, then we fail. Right now we only support
running on the same GPU as the compositor, so any of these being
missing means that is not the case.
---
src/wayland-egldisplay.c | 153 +++++++++++++++++++++++++++++++++++----
1 file changed, 138 insertions(+), 15 deletions(-)
diff --git a/src/wayland-egldisplay.c b/src/wayland-egldisplay.c
index a0370a5..8b7394a 100644
--- a/src/wayland-egldisplay.c
+++ b/src/wayland-egldisplay.c
@@ -29,13 +29,19 @@
#include "wayland-eglsurface.h"
#include "wayland-eglhandle.h"
#include "wayland-eglutils.h"
+#include "wayland-drm-client-protocol.h"
#include <string.h>
#include <stdlib.h>
#include <assert.h>
+#include <unistd.h>
+#include <fcntl.h>
typedef struct WlServerProtocolsRec {
EGLBoolean hasEglStream;
EGLBoolean hasDmaBuf;
+ EGLBoolean hasDrm;
+ struct wl_drm *wldrm;
+ char *drm_name;
} WlServerProtocols;
/* TODO: Make global display lists hang off platform data */
@@ -241,6 +247,40 @@ static const struct wl_registry_listener registry_listener = {
registry_handle_global_remove
};
+static void wl_drm_device(void *data, struct wl_drm *wl_drm, const char *name)
+{
+ WlServerProtocols *protocols = (WlServerProtocols *)data;
+ (void) wl_drm;
+
+ protocols->drm_name = strdup(name);
+}
+
+static void wl_drm_authenticated(void *data, struct wl_drm *wl_drm)
+{
+ (void) data;
+ (void) wl_drm;
+}
+static void wl_drm_format(void *data, struct wl_drm *wl_drm, uint32_t format)
+{
+ (void) data;
+ (void) wl_drm;
+ (void) format;
+}
+static void wl_drm_capabilities(void *data, struct wl_drm *wl_drm, uint32_t value)
+{
+ (void) data;
+ (void) wl_drm;
+ (void) value;
+}
+
+static const struct wl_drm_listener drmListener = {
+ .device = wl_drm_device,
+ .authenticated = wl_drm_authenticated,
+ .format = wl_drm_format,
+ .capabilities = wl_drm_capabilities,
+};
+
+
static void
registry_handle_global_check_protocols(
void *data,
@@ -262,6 +302,12 @@ registry_handle_global_check_protocols(
(version >= 3)) {
protocols->hasDmaBuf = EGL_TRUE;
}
+
+ if ((strcmp(interface, "wl_drm") == 0) && (version >= 2)) {
+ protocols->hasDrm = EGL_TRUE;
+ protocols->wldrm = wl_registry_bind(registry, name, &wl_drm_interface, 2);
+ wl_drm_add_listener(protocols->wldrm, &drmListener, protocols);
+ }
}
static void
@@ -389,8 +435,8 @@ EGLBoolean wlEglTerminateHook(EGLDisplay dpy)
return res;
}
-static void checkServerProtocols(struct wl_display *nativeDpy,
- WlServerProtocols *protocols)
+static void getServerProtocolsInfo(struct wl_display *nativeDpy,
+ WlServerProtocols *protocols)
{
struct wl_display *wrapper = NULL;
struct wl_registry *wlRegistry = NULL;
@@ -418,6 +464,11 @@ static void checkServerProtocols(struct wl_display *nativeDpy,
protocols);
if (ret == 0) {
wl_display_roundtrip_queue(nativeDpy, queue);
+ if (protocols->hasDrm) {
+ wl_display_roundtrip_queue(nativeDpy, queue);
+ /* destroy our wl_drm object */
+ wl_drm_destroy(protocols->wldrm);
+ }
}
if (queue) {
@@ -438,9 +489,13 @@ EGLDisplay wlEglGetPlatformDisplayExport(void *data,
WlServerProtocols protocols;
EGLint numDevices = 0;
int i = 0;
+ EGLDeviceEXT *eglDeviceList = NULL;
EGLDeviceEXT eglDevice = NULL;
+ EGLDeviceEXT tmpDev = NULL;
EGLint err = EGL_SUCCESS;
EGLBoolean useInitRefCount = EGL_FALSE;
+ const char *dev_exts;
+ const char *dev_name;
if (platform != EGL_PLATFORM_WAYLAND_EXT) {
wlEglSetError(data, EGL_BAD_PARAMETER);
@@ -480,7 +535,6 @@ EGLDisplay wlEglGetPlatformDisplayExport(void *data,
display = calloc(1, sizeof(*display));
if (!display) {
- wlExternalApiUnlock();
err = EGL_BAD_ALLOC;
goto fail;
}
@@ -498,7 +552,6 @@ EGLDisplay wlEglGetPlatformDisplayExport(void *data,
if (!display->nativeDpy) {
display->nativeDpy = wl_display_connect(NULL);
if (!display->nativeDpy) {
- wlExternalApiUnlock();
err = EGL_BAD_ALLOC;
goto fail;
}
@@ -508,26 +561,85 @@ EGLDisplay wlEglGetPlatformDisplayExport(void *data,
}
memset(&protocols, 0, sizeof(protocols));
- checkServerProtocols(display->nativeDpy, &protocols);
+ /*
+ * This is where we check the supported protocols on the compositor,
+ * and bind to wl_drm to get the device name.
+ * protocols.drm_name will be allocated here if using wl_drm
+ */
+ getServerProtocolsInfo(display->nativeDpy, &protocols);
- if (!protocols.hasEglStream && !protocols.hasDmaBuf) {
- wlExternalApiUnlock();
- goto fail;
+ if (!protocols.hasDrm || (!protocols.hasEglStream && !protocols.hasDmaBuf)) {
+ goto fail_cleanup_protocols;
}
- if (!pData->egl.queryDevices(1, &eglDevice, &numDevices) || numDevices == 0) {
- wlExternalApiUnlock();
- goto fail;
+ /* Get the number of devices available */
+ if (!pData->egl.queryDevices(-1, NULL, &numDevices) || numDevices == 0) {
+ goto fail_cleanup_protocols;
+ }
+
+ eglDeviceList = calloc(numDevices, sizeof(*eglDeviceList));
+ if (!eglDeviceList) {
+ goto fail_cleanup_protocols;
+ }
+
+ /*
+ * Now we need to find an EGLDevice. If wl_drm is in use we will try to find one that
+ * matches the device the compositor is using. We know that device is an nvidia device
+ * since we just checked that above.
+ */
+ if (!pData->egl.queryDevices(numDevices, eglDeviceList, &numDevices) || numDevices == 0) {
+ goto fail_cleanup_devices;
}
+
+ if (protocols.drm_name) {
+ for (int i = 0; i < numDevices; i++) {
+ tmpDev = eglDeviceList[i];
+
+ /*
+ * To check against the wl_drm name, we need to check if we can use
+ * the drm extension
+ */
+ dev_exts = display->data->egl.queryDeviceString(tmpDev,
+ EGL_EXTENSIONS);
+ if (dev_exts) {
+ if (wlEglFindExtension("EGL_EXT_device_drm_render_node", dev_exts)) {
+ dev_name =
+ display->data->egl.queryDeviceString(tmpDev,
+ EGL_DRM_RENDER_NODE_FILE_EXT);
+
+ if (dev_name) {
+ /*
+ * At this point we have gotten the name from wl_drm, gotten
+ * the drm node from the EGLDevice. If they match, then
+ * this is the final device to use, since it is the compositor's
+ * device.
+ */
+ if (strcmp(dev_name, protocols.drm_name) == 0) {
+ eglDevice = eglDeviceList[0];
+ break;
+ }
+ }
+ }
+ }
+ }
+ }
+
+ /*
+ * Right now we are pretty much limited to running on the same GPU as the
+ * compositor. If we couldn't find an EGLDevice that has EGL_EXT_device_drm_render_node
+ * and the same DRM device path, then fail.
+ */
+ if (!eglDevice) {
+ goto fail_cleanup_devices;
+ }
+
display->devDpy = wlGetInternalDisplay(pData, eglDevice);
if (display->devDpy == NULL) {
- wlExternalApiUnlock();
- goto fail;
+ goto fail_cleanup_devices;
}
if (!wlEglInitializeMutex(&display->mutex)) {
- wlExternalApiUnlock();
- goto fail;
+ goto fail_cleanup_devices;
}
display->refCount = 1;
WL_LIST_INIT(&display->wlEglSurfaceList);
@@ -537,10 +649,21 @@ EGLDisplay wlEglGetPlatformDisplayExport(void *data,
// in wlEglDisplayList.
wl_list_insert(&wlEglDisplayList, &display->link);
+ free(eglDeviceList);
+ if (protocols.drm_name) {
+ free(protocols.drm_name);
+ }
wlExternalApiUnlock();
return display;
+fail_cleanup_devices:
+ free(eglDeviceList);
+fail_cleanup_protocols:
+ if (protocols.drm_name) {
+ free(protocols.drm_name);
+ }
fail:
+ wlExternalApiUnlock();
if (display->ownNativeDpy) {
wl_display_disconnect(display->nativeDpy);

View File

@ -0,0 +1,51 @@
From daab8546eca8428543a4d958a2c53fc747f70672 Mon Sep 17 00:00:00 2001
From: Oleksandr Kulkov <adamant-pwn@users.noreply.github.com>
Date: Fri, 29 Oct 2021 01:13:04 +0200
Subject: [PATCH] generate wayland-drm-client-protocol.h
---
Makefile.am | 3 ++-
src/meson.build | 1 +
wayland-drm/meson.build | 6 ++++--
3 files changed, 7 insertions(+), 3 deletions(-)
diff --git a/Makefile.am b/Makefile.am
index 8129539..9463349 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -49,7 +49,8 @@ libnvidia_egl_wayland_la_built_private_protocols = \
libnvidia_egl_wayland_la_built_client_headers = \
wayland-eglstream/wayland-eglstream-client-protocol.h \
- wayland-eglstream/wayland-eglstream-controller-client-protocol.h
+ wayland-eglstream/wayland-eglstream-controller-client-protocol.h \
+ wayland-drm/wayland-drm-client-protocol.h
libnvidia_egl_wayland_la_built_server_headers = \
wayland-eglstream/wayland-eglstream-server-protocol.h \
diff --git a/src/meson.build b/src/meson.build
index a489fa3..6f69e09 100644
--- a/src/meson.build
+++ b/src/meson.build
@@ -47,6 +47,7 @@ src = [
wayland_eglstream_controller_protocol_c,
wayland_eglstream_controller_client_protocol_h,
wayland_drm_protocol_c,
+ wayland_drm_client_protocol_h,
wayland_drm_server_protocol_h,
]
diff --git a/wayland-drm/meson.build b/wayland-drm/meson.build
index b3b3bcb..2a29afe 100644
--- a/wayland-drm/meson.build
+++ b/wayland-drm/meson.build
@@ -1,5 +1,7 @@
-foreach output_type: ['server-header', 'public-code']
- if output_type == 'server-header'
+foreach output_type: ['client-header', 'server-header', 'public-code']
+ if output_type == 'client-header'
+ output_file = 'wayland-drm-client-protocol.h'
+ elif output_type == 'server-header'
output_file = 'wayland-drm-server-protocol.h'
else
output_file = 'wayland-drm-protocol.c'

210
egl-wayland.spec Normal file
View File

@ -0,0 +1,210 @@
Name: egl-wayland
Version: 1.1.9
Release: 2%{?dist}
Summary: Wayland EGL External Platform library
License: MIT
URL: https://github.com/NVIDIA/%{name}
Source0: %url/archive/%{version}/%{name}-%{version}.tar.gz
Source1: 10_nvidia_wayland.json
Source2: 15_nvidia_gbm.json
Patch0: %url/commit/d4937adc5cd04ac7df98fc5616e40319fb52fdee.patch
Patch1: %url/commit/daab8546eca8428543a4d958a2c53fc747f70672.patch
Patch2: %url/commit/582b2d345abaa0e313cf16c902e602084ea59551.patch
BuildRequires: meson
BuildRequires: libtool
BuildRequires: eglexternalplatform-devel
%if 0%{?fedora}
BuildRequires: libglvnd-devel
%else
BuildRequires: mesa-libEGL-devel
%endif
BuildRequires: wayland-devel
BuildRequires: wayland-protocols-devel
# Required for directory ownership
Requires: libglvnd-egl%{?_isa}
%description
Wayland EGL External Platform library
%package devel
Summary: Wayland EGL External Platform library development package
Requires: %{name}%{?_isa} = %{version}-%{release}
%description devel
Wayland EGL External Platform library development package
%prep
%autosetup -p1
%if 0%{?rhel}
sed -i -e 's@>= 0.50@>= 0.47@g' meson.build
%endif
%build
%meson
%meson_build
%install
%meson_install
install -m 0755 -d %{buildroot}%{_datadir}/egl/egl_external_platform.d/
install -pm 0644 %{SOURCE1} %{SOURCE2} %{buildroot}%{_datadir}/egl/egl_external_platform.d/
find %{buildroot} -name '*.la' -exec rm -f {} ';'
%ldconfig_scriptlets
%files
%doc README.md
%license COPYING
%{_libdir}/*.so.*
%{_datadir}/egl/egl_external_platform.d/10_nvidia_wayland.json
%{_datadir}/egl/egl_external_platform.d/15_nvidia_gbm.json
%files devel
%{_libdir}/libnvidia-egl-wayland.so
%{_libdir}/pkgconfig/wayland-eglstream.pc
%{_datadir}/pkgconfig/wayland-eglstream-protocols.pc
%{_datadir}/wayland-eglstream/
%changelog
* Tue Jun 28 2022 Olivier Fourdan <ofourdan@redhat.com> - 1.1.9-2
- Install 15_nvidia_gbm.json
Resolves: rhbz#2101695
* Tue Jan 25 2022 Dave Airlie <airlied@redhat.com> - 1.1.9-1
- Update to egl-wayland 1.1.9 like Fedora
* Mon Aug 09 2021 Mohan Boddu <mboddu@redhat.com> - 1.1.7-3
- Rebuilt for IMA sigs, glibc 2.34, aarch64 flags
Related: rhbz#1991688
* Wed Jul 7 2021 Olivier Fourdan <ofourdan@redhat.com> - 1.1.7-2
- Rebuild for annobin-9.79 (#1975875)
* Thu Jul 1 2021 Olivier Fourdan <ofourdan@redhat.com> - 1.1.7-1
- Update to 1.1.7 (#1975875)
* Thu Apr 15 2021 Mohan Boddu <mboddu@redhat.com> - 1.1.6-3
- Rebuilt for RHEL 9 BETA on Apr 15th 2021. Related: rhbz#1947937
* Tue Jan 26 2021 Fedora Release Engineering <releng@fedoraproject.org> - 1.1.6-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
* Thu Jan 7 2021 Leigh Scott <leigh123linux@gmail.com> - 1.1.6-1
- Update to 1.1.6
* Fri Aug 14 2020 Leigh Scott <leigh123linux@gmail.com> - 1.1.5-3
- Add upstream patch to address rhbz#1842473
* Mon Jul 27 2020 Fedora Release Engineering <releng@fedoraproject.org> - 1.1.5-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
* Mon Jun 01 2020 Leigh Scott <leigh123linux@gmail.com> - 1.1.5-1
- Update to 1.1.5
* Mon Mar 30 2020 leigh123linux <leigh123linux@googlemail.com> - 1.1.4-4
- Use upstream commit to address missing mesa includes
* Tue Jan 28 2020 Fedora Release Engineering <releng@fedoraproject.org> - 1.1.4-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
* Mon Dec 16 2019 Leigh Scott <leigh123linux@gmail.com> - 1.1.4-2
- Add patch to add missing mesa includes
* Sun Sep 15 2019 Leigh Scott <leigh123linux@googlemail.com> - 1.1.4-1
- Update to 1.1.4
* Wed Jul 24 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.1.3-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
* Sun Jun 02 2019 Leigh Scott <leigh123linux@googlemail.com> - 1.1.3-1
- Update to 1.1.3
* Tue Apr 16 2019 Adam Williamson <awilliam@redhat.com> - 1.1.2-3
- Rebuild with Meson fix for #1699099
* Sat Mar 30 2019 Leigh Scott <leigh123linux@googlemail.com> - 1.1.2-2
- Switch to upstream fix
* Fri Feb 01 2019 Leigh Scott <leigh123linux@googlemail.com> - 1.1.2-1
- Update to 1.1.2
* Thu Jan 31 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.1.1-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
* Thu Dec 06 2018 Leigh Scott <leigh123linux@googlemail.com> - 1.1.1-3
- Fix the same crappy warning f28 generates
* Thu Dec 06 2018 Leigh Scott <leigh123linux@googlemail.com> - 1.1.1-2
- Fix the crappy warning epel7 generates
* Thu Dec 06 2018 Leigh Scott <leigh123linux@googlemail.com> - 1.1.1-1
- Update to 1.1.1
* Mon Nov 26 2018 Leigh Scott <leigh123linux@googlemail.com> - 1.1.0-0.2.20181015git0eb29d4
- Update to latest git snapshot (rhbz#1653118)
* Mon Aug 20 2018 Leigh Scott <leigh123linux@googlemail.com> - 1.1.0-0.1.20180916git1676d1d
- Update to 1.1.0 snapshot
* Thu Jul 12 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.5-0.2.20180626git395ce9f
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
* Sat Jun 30 2018 Leigh Scott <leigh123linux@googlemail.com> - 1.0.5-0.1.20180626git395ce9f
- Update to 1.0.5 snapshot
* Sat Jun 16 2018 Leigh Scott <leigh123linux@googlemail.com> - 1.0.4-0.1.20180602git4ab0873
- Update to 1.0.4 snapshot
* Tue Feb 06 2018 Leigh Scott <leigh123linux@googlemail.com> - 1.0.3-2.20180201git6f5f7d0
- Update to latest git snapshot
- Switch to meson
- Install .so file to -devel as it's listed in wayland-eglstream.pc
- Fix directory ownership
* Wed Jan 31 2018 Jonas Ådahl <jadahl@redhat.com> - 1.0.3-1.20180111gitb283689
- Update to 1.0.3
- Add -devel package
* Thu Aug 03 2017 Leigh Scott <leigh123linux@googlemail.com> - 1.0.2-0.4.20170802git1f4b1fd
- Update to latest git snapshot
* Wed Aug 02 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.2-0.3.20170628git818b613
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild
* Wed Jul 26 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.2-0.2.20170628git818b613
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
* Wed Jun 28 2017 Leigh Scott <leigh123linux@googlemail.com> - 1.0.2-0.1.20170628git818b613
- Update to 1.0.2 git
* Wed Mar 08 2017 Leigh Scott <leigh123linux@googlemail.com> - 1.0.1-0.1.20170308git582fbf3
- Update to 1.0.1 git
* Tue Feb 07 2017 Leigh Scott <leigh123linux@googlemail.com> - 1.0.0-0.7.20170207git05eb000
- Add license file
* Thu Feb 02 2017 Leigh Scott <leigh123linux@googlemail.com> - 1.0.0-0.6.20170120git743d702
- Add requires libglvnd-egl
- Make review changes
* Wed Feb 01 2017 Leigh Scott <leigh123linux@googlemail.com> - 1.0.0-0.5.20170120git743d702
- Drop devel sub-package
* Wed Feb 01 2017 Leigh Scott <leigh123linux@googlemail.com> - 1.0.0-0.4.20170120git743d702
- Add 10_nvidia_wayland.json to libs sub-package
* Wed Feb 01 2017 Leigh Scott <leigh123linux@googlemail.com> - 1.0.0-0.3.20170120git743d702
- Add loader directory to common sub-package
- Move libs to sub-package
* Fri Jan 20 2017 Leigh Scott <leigh123linux@googlemail.com> - 1.0.0-0.2.20170120git743d702
- Add date to release
* Fri Jan 20 2017 Leigh Scott <leigh123linux@googlemail.com> - 1.0.0-0.1.git743d702
- First build

6
gating.yaml Normal file
View File

@ -0,0 +1,6 @@
--- !Policy
product_versions:
- rhel-9
decision_context: osci_compose_gate
rules:
- !PassingTestCaseRule {test_case_name: desktop-qe.desktop-ci.tier1-gating.functional}

1
sources Normal file
View File

@ -0,0 +1 @@
SHA512 (egl-wayland-1.1.9.tar.gz) = 3125f4130a5a738f8ecb2acf4d1a7936ca44958a78ade29118222fcd0b5d46f6edf6e18f4e992f541294e08e88c54a8dc231eb2bdcfcd7d56ac543f4e1ed3f8c