diff --git a/system/libdrm/files/patch-libkms_vmwgfx.c b/system/libdrm/files/patch-libkms_vmwgfx.c new file mode 100644 index 00000000..17e68b6c --- /dev/null +++ b/system/libdrm/files/patch-libkms_vmwgfx.c @@ -0,0 +1,27 @@ +# the defintion of ERESTART is behind a check for _KERNEL, but +# defining that causes errno to not be defined. fortunately, there's +# an alternative switch. unfortunately, those differ by platform and +# _WANT_KERNEL_ERRNO is too recent to be part of any release, so just +# define ERESTART if we still don't have it after including errno.h +# +--- libkms/vmwgfx.c.orig 2018-05-09 22:26:03 UTC ++++ libkms/vmwgfx.c +@@ -26,10 +26,18 @@ + **************************************************************************/ + + ++#if defined (__FreeBSD__) || defined (__FreeBSD_kernel__) ++#define _WANT_KERNEL_ERRNO ++#elif defined(__DragonFly__) ++#define _KERNEL_STRUCTURES ++#endif + #include + #include + #include + #include "internal.h" ++#ifndef ERESTART ++#define ERESTART (-1) ++#endif + + #include "xf86drm.h" + #include "libdrm_macros.h" diff --git a/system/libdrm/files/patch-x-nouveau-Makefile.in b/system/libdrm/files/patch-x-nouveau-Makefile.in new file mode 100644 index 00000000..c1ecc200 --- /dev/null +++ b/system/libdrm/files/patch-x-nouveau-Makefile.in @@ -0,0 +1,11 @@ +--- ./nouveau/Makefile.in.orig 2018-10-16 16:49:16.000000000 +0200 ++++ ./nouveau/Makefile.in 2022-04-08 16:19:24.374500000 +0200 +@@ -558,7 +558,7 @@ + -I$(top_srcdir) \ + $(PTHREADSTUBS_CFLAGS) \ + -I$(top_srcdir)/include/drm \ +- -DDEBUG ++ + + libdrm_nouveau_la_LTLIBRARIES = libdrm_nouveau.la + libdrm_nouveau_ladir = $(libdir)