pkgsrc-WIP-changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

modular-xorg-server-dfbsd: Update wip/modular-xorg-server to 1.19.6



Module Name:	pkgsrc-wip
Committed By:	David Shao <davshao%gmail.com@localhost>
Pushed By:	dshao
Date:		Mon Apr 30 20:35:25 2018 -0700
Changeset:	4a2e511094e39b6fc704f750ee7aca71c3f6eef1

Modified Files:
	modular-xorg-server-dfbsd/Makefile
	modular-xorg-server-dfbsd/Makefile.common
	modular-xorg-server-dfbsd/TODO
	modular-xorg-server-dfbsd/buildlink3.mk
	modular-xorg-server-dfbsd/distinfo
	modular-xorg-server-dfbsd/options.mk
	modular-xorg-server-dfbsd/patches/patch-config_devd.c
	modular-xorg-server-dfbsd/patches/patch-configure
	modular-xorg-server-dfbsd/patches/patch-hw_xfree86_common_xf86Xinput.c
Added Files:
	modular-xorg-server-dfbsd/patches/patch-glx_glxscreens.c
	modular-xorg-server-dfbsd/patches/patch-hw_xfree86_common_xf86AutoConfig.c
	modular-xorg-server-dfbsd/patches/patch-hw_xfree86_os-support_solaris_solaris-amd64.S
Removed Files:
	modular-xorg-server-dfbsd/patches/patch-Xi_sendexev.c
	modular-xorg-server-dfbsd/patches/patch-dix_events.c
	modular-xorg-server-dfbsd/patches/patch-dix_swapreq.c

Log Message:
modular-xorg-server-dfbsd: Update wip/modular-xorg-server to 1.19.6

To see a diff of this commit:
https://wip.pkgsrc.org/cgi-bin/gitweb.cgi?p=pkgsrc-wip.git;a=commitdiff;h=4a2e511094e39b6fc704f750ee7aca71c3f6eef1

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

diffstat:
 modular-xorg-server-dfbsd/Makefile                 |   7 +-
 modular-xorg-server-dfbsd/Makefile.common          |  24 ++---
 modular-xorg-server-dfbsd/TODO                     |  13 +--
 modular-xorg-server-dfbsd/buildlink3.mk            |   4 +-
 modular-xorg-server-dfbsd/distinfo                 |  22 ++---
 modular-xorg-server-dfbsd/options.mk               |  31 ++++---
 .../patches/patch-Xi_sendexev.c                    |  65 --------------
 .../patches/patch-config_devd.c                    | 100 +++++++++++++++++----
 modular-xorg-server-dfbsd/patches/patch-configure  |   6 +-
 .../patches/patch-dix_events.c                     |  24 -----
 .../patches/patch-dix_swapreq.c                    |  25 ------
 .../patches/patch-glx_glxscreens.c                 |  26 ++++++
 .../patch-hw_xfree86_common_xf86AutoConfig.c       |  27 ++++++
 .../patches/patch-hw_xfree86_common_xf86Xinput.c   |  10 ++-
 ...h-hw_xfree86_os-support_solaris_solaris-amd64.S |  62 +++++++++++++
 15 files changed, 250 insertions(+), 196 deletions(-)

diffs:
diff --git a/modular-xorg-server-dfbsd/Makefile b/modular-xorg-server-dfbsd/Makefile
index 4dda1b2c29..87ddec2efc 100644
--- a/modular-xorg-server-dfbsd/Makefile
+++ b/modular-xorg-server-dfbsd/Makefile
@@ -1,8 +1,8 @@
-# $NetBSD: Makefile,v 1.113 2017/07/28 21:10:00 wiz Exp $
+# $NetBSD: Makefile,v 1.115 2018/03/07 11:57:38 wiz Exp $
 
 DISTNAME=	xorg-server-${XORG_VERSION}
 PKGNAME=	modular-${DISTNAME}
-PKGREVISION=	2
+PKGREVISION=	1
 
 MAINTAINER=	pkgsrc-users%NetBSD.org@localhost
 COMMENT=	Modular X11 server from modular X.org
@@ -20,7 +20,4 @@ CONFIGURE_ARGS.SunOS+=	--disable-input-thread
 
 .include "options.mk"
 
-pre-patch:
-	cd ${WRKSRC} && autoreconf -vif
-
 .include "../../mk/bsd.pkg.mk"
diff --git a/modular-xorg-server-dfbsd/Makefile.common b/modular-xorg-server-dfbsd/Makefile.common
index ecb3711bbe..f9e9b8c7d4 100644
--- a/modular-xorg-server-dfbsd/Makefile.common
+++ b/modular-xorg-server-dfbsd/Makefile.common
@@ -1,8 +1,8 @@
-# $NetBSD: Makefile.common,v 1.17 2017/04/10 13:10:19 jperkin Exp $
+# $NetBSD: Makefile.common,v 1.21 2018/03/07 11:57:38 wiz Exp $
 # used by x11/modular-xorg-server/Makefile
 # used by x11/modular-xorg-xephyr/Makefile
 
-XORG_VERSION=	1.19.3
+XORG_VERSION=	1.19.6
 CATEGORIES=	x11
 MASTER_SITES=	${MASTER_SITE_XORG:=xserver/}
 EXTRACT_SUFX=	.tar.bz2
@@ -12,7 +12,7 @@ LICENSE=	mit AND modified-bsd AND x11 # with no-advertising clause
 
 GNU_CONFIGURE=	yes
 USE_LIBTOOL=	yes
-USE_TOOLS+=	gmake pkg-config autoconf automake autoreconf
+USE_TOOLS+=	gmake pkg-config
 USE_LANGUAGES+=	c99
 
 PKGCONFIG_OVERRIDE+=	xorg-server.pc.in
@@ -25,12 +25,12 @@ OWN_DIRS+=		${VARBASE}/log
 OWN_DIRS+=		${XKB_OUTPUT_DIR}
 XKB_OUTPUT_DIR?=	${VARBASE}/db/xkb # XXX sync with xkeyboard-config
 
-CONFIGURE_ARGS+=	--localstatedir=${VARBASE}
+CONFIGURE_ARGS+=	--localstatedir=${VARBASE:Q}
 CONFIGURE_ARGS+=	--with-xkb-output=${XKB_OUTPUT_DIR:Q}
 
-# .if !empty(USE_TOOLS:Mauto*)
-# TOOLS_DEPENDS+=	xorg-util-macros>=1.1.5:../../devel/xorg-util-macros
-# .endif
+.if !empty(USE_TOOLS:Mauto*)
+TOOLS_DEPENDS+=	xorg-util-macros>=1.1.5:../../devel/xorg-util-macros
+.endif
 
 DEPENDS+=	xkbcomp-[0-9]*:../../x11/xkbcomp
 DEPENDS+=	xkeyboard-config-[0-9]*:../../x11/xkeyboard-config
@@ -47,7 +47,7 @@ CONFIGURE_ENV+=		ac_cv_tls=no
 CONFIGURE_ARGS+=	--disable-glx-tls
 .  endif
 .endif
-CONFIGURE_ARGS+=	--with-os-name=${MACHINE_PLATFORM}
+CONFIGURE_ARGS+=	--with-os-name=${MACHINE_PLATFORM:Q}
 
 CONFIGURE_ARGS+=	--with-fontrootdir=${PREFIX}/share/fonts/X11
 
@@ -111,7 +111,6 @@ BUILDLINK_API_DEPENDS.xfont+=		xfont>=1.4.2
 BUILDLINK_API_DEPENDS.pixman+=		pixman>=0.21.8
 
 BUILD_DEPENDS+=		tradcpp-[0-9]*:../../devel/tradcpp
-BUILD_DEPENDS+=		font-util-[0-9]*:../../fonts/font-util
 CONFIGURE_ENV+=		ac_cv_path_RAWCPP="${PREFIX}/bin/tradcpp -Uunix"
 
 .if ${OPSYS} == "NetBSD" || ${OPSYS} == "OpenBSD" || ${OPSYS} == "Bitrig" || ${OPSYS} == "MirBSD"
@@ -121,26 +120,20 @@ CONFIGURE_ARGS+=	--with-sha1=libc
 CONFIGURE_ARGS+=	--with-sha1=libnettle
 .endif
 
-.include "../../devel/xorg-util-macros/buildlink3.mk"
-
 .include "../../devel/ncurses/buildlink3.mk"
 .include "../../devel/zlib/buildlink3.mk"
 .include "../../fonts/libfontenc/buildlink3.mk"
 BUILDLINK_API_DEPENDS.libpciaccess+=	libpciaccess>=0.11.0
 BUILDLINK_DEPMETHOD.libpciaccess=	full
 .include "../../sysutils/libpciaccess/buildlink3.mk"
-.include "../../x11/xorgproto/buildlink3.mk"
 .include "../../x11/evieext/buildlink3.mk"
 .include "../../x11/libX11/buildlink3.mk"
 .include "../../x11/libXau/buildlink3.mk"
 .include "../../x11/libXaw/buildlink3.mk"
-.include "../../x11/libXdmcp/buildlink3.mk"
 BUILDLINK_API_DEPENDS.libXext+=	libXext>=1.1.1
 .include "../../x11/libXext/buildlink3.mk"
 .include "../../x11/libXfixes/buildlink3.mk"
 .include "../../x11/libXfont2/buildlink3.mk"
-.include "../../x11/libXmu/buildlink3.mk"
-.include "../../x11/libXpm/buildlink3.mk"
 .include "../../x11/libXt/buildlink3.mk"
 .include "../../x11/libXxf86misc/buildlink3.mk"
 .include "../../x11/libXxf86vm/buildlink3.mk"
@@ -149,5 +142,6 @@ BUILDLINK_API_DEPENDS.libXext+=	libXext>=1.1.1
 .include "../../x11/libxkbui/buildlink3.mk"
 .include "../../x11/pixman/buildlink3.mk"
 .include "../../x11/xcb-util-keysyms/buildlink3.mk"
+.include "../../x11/xorgproto/buildlink3.mk"
 .include "../../x11/xtrans/buildlink3.mk"
 .include "../../mk/pthread.buildlink3.mk"
diff --git a/modular-xorg-server-dfbsd/TODO b/modular-xorg-server-dfbsd/TODO
index 3077ec0e42..93e17a5366 100644
--- a/modular-xorg-server-dfbsd/TODO
+++ b/modular-xorg-server-dfbsd/TODO
@@ -1,13 +1,4 @@
 Copy port to x11/modular-xorg-server, do not install from wip.
 
-Waiting for devd patches required on latest FreeBSD and DragonFly
-submitted in
-pkg/50200 (x11/modular-xorg-server)
-to be accepted.
-
-Normal pkgsrc configure no longer works, need full autoreconf instead.
-Put autoreconf in pre-patch because not sure how else to apply
-patches to configure.
-
-Unsure whether RegisterBlockAndWakeupHandlers() and
-RemoveBlockAndWakeupHandlers() are used anymore after 1.19 API shift. 
+Port devd patches for 1.19.6 that have not been merged
+into FreeBSD ports, supports evdev.
diff --git a/modular-xorg-server-dfbsd/buildlink3.mk b/modular-xorg-server-dfbsd/buildlink3.mk
index fb67cf13a2..5912606e85 100644
--- a/modular-xorg-server-dfbsd/buildlink3.mk
+++ b/modular-xorg-server-dfbsd/buildlink3.mk
@@ -1,4 +1,4 @@
-# $NetBSD: buildlink3.mk,v 1.20 2017/01/07 22:34:56 maya Exp $
+# $NetBSD: buildlink3.mk,v 1.21 2018/03/07 11:57:38 wiz Exp $
 
 BUILDLINK_TREE+=	modular-xorg-server
 
@@ -21,7 +21,6 @@ BUILDLINK_DEPMETHOD.libpciaccess=	full
 .include "../../sysutils/libpciaccess/buildlink3.mk"
 .include "../../x11/pixman/buildlink3.mk"
 
-.include "../../x11/xorgproto/buildlink3.mk"
 .if !empty(USE_OLD_MODULAR_XORG_SERVER:M[yY][eE][sS])
 .include "../../graphics/MesaLib7/buildlink3.mk" # XXX should not be needed for non-dri build
 .include "../../x11/libXfont/buildlink3.mk"
@@ -29,6 +28,7 @@ BUILDLINK_DEPMETHOD.libpciaccess=	full
 .include "../../x11/libXfont2/buildlink3.mk"
 .include "../../graphics/MesaLib/buildlink3.mk" # XXX should not be needed for non-dri build
 .endif
+.include "../../x11/xorgproto/buildlink3.mk"
 .endif # MODULAR_XORG_SERVER_BUILDLINK3_MK
 
 BUILDLINK_TREE+=	-modular-xorg-server
diff --git a/modular-xorg-server-dfbsd/distinfo b/modular-xorg-server-dfbsd/distinfo
index f3e0f40b39..12c87a2eb7 100644
--- a/modular-xorg-server-dfbsd/distinfo
+++ b/modular-xorg-server-dfbsd/distinfo
@@ -1,19 +1,18 @@
-$NetBSD: distinfo,v 1.83 2017/07/28 21:10:00 wiz Exp $
+$NetBSD: distinfo,v 1.87 2018/01/25 15:06:10 jperkin Exp $
 
-SHA1 (xorg-server-1.19.3.tar.bz2) = 77f580ffa22a8bbcc3536e74e19114e446417a9c
-RMD160 (xorg-server-1.19.3.tar.bz2) = afa8708054016d4fa3632bf1db0bc462731717b4
-SHA512 (xorg-server-1.19.3.tar.bz2) = b988897418399e1361fdcca9465a781f55f8f6fbfdc5a59edfaee9046a0c6ad7a76f348d88b6004ce3d3fb3966b4c5af0b854f6549c32b2b8d7a43758809f669
-Size (xorg-server-1.19.3.tar.bz2) = 6050221 bytes
-SHA1 (patch-Xi_sendexev.c) = 46a165049d4b15c472736d3863aa4efad39418bc
+SHA1 (xorg-server-1.19.6.tar.bz2) = 2dd560ac49bdbda7f67166546af43541fabf517f
+RMD160 (xorg-server-1.19.6.tar.bz2) = c2b6f9fe3957c99cddd44bc3ae38343a1c4f314e
+SHA512 (xorg-server-1.19.6.tar.bz2) = 38519a8d0af9dd034045fc346959496dd718fa59b6188307974797a1cd9c349deb54987f6232ea8396baf810dcc710c0ff191f76ed2186cae4d44921b3680412
+Size (xorg-server-1.19.6.tar.bz2) = 5984528 bytes
 SHA1 (patch-config_config-backends.h) = f44868caa51e972a76949f73ac6083640af2c351
 SHA1 (patch-config_config.c) = 5a3fe4cb6c2170335ab547f438386cff77a9c152
-SHA1 (patch-config_devd.c) = c4f968f66903c858e0bb65cafb5229be77f10a2f
-SHA1 (patch-configure) = 9e9f497f14d563ef66f25c637a14b0bea2243c3f
-SHA1 (patch-dix_events.c) = a7ede761198583f1d59c4def49db48725a46bd21
-SHA1 (patch-dix_swapreq.c) = 66643fbd396d0b4222ba4a3f09c4bbe3f0083a33
+SHA1 (patch-config_devd.c) = 4e4cf2f61507e350cccdc04742b7d985aa84844f
+SHA1 (patch-configure) = 1f476fd71d97b84bc2e581f9b8e7d582eaece023
+SHA1 (patch-glx_glxscreens.c) = 1e8861f49537e4a23295128289dd3ede4ecb2035
+SHA1 (patch-hw_xfree86_common_xf86AutoConfig.c) = 765bbc7c8c61a0ffa5da54099e212cb981ef3bd0
 SHA1 (patch-hw_xfree86_common_xf86Config.c) = 7964ac8d32d4fcea113c8950661ab921c63ad9d0
 SHA1 (patch-hw_xfree86_common_xf86Globals.c) = 870100ea740b2c0bc1261355d3fcdf17ec50f64f
-SHA1 (patch-hw_xfree86_common_xf86Xinput.c) = 5217a62409708b085a1f83bb0401376e030fb34f
+SHA1 (patch-hw_xfree86_common_xf86Xinput.c) = 5c39ab681afa54ba24465fb9243b8fc2e71fd0ab
 SHA1 (patch-hw_xfree86_common_xf86pciBus.c) = 896825ba12646431cba603938d118acbdde305dd
 SHA1 (patch-hw_xfree86_common_xf86sbusBus.h) = f56f87336b2f669413ebb1005a2b64568a111f92
 SHA1 (patch-hw_xfree86_dri2_dri2.c) = 44aa2e3d15a8985e2541a405b8a5ec7b7813b29f
@@ -21,6 +20,7 @@ SHA1 (patch-hw_xfree86_os-support_bsd_arm__video.c) = 9c03b24f44eafc5fabe27e9d6c
 SHA1 (patch-hw_xfree86_os-support_bsd_bsd__VTsw.c) = 90343f694c27a6fdd5070e1167687943bd056a99
 SHA1 (patch-hw_xfree86_os-support_bsd_i386__video.c) = 9bd30fa3ed7c73afd0b15e5cf5286de439f19351
 SHA1 (patch-hw_xfree86_os-support_bus_Sbus.c) = 0035b970bdae1bab51b8ca6bfeed060ec4df3a60
+SHA1 (patch-hw_xfree86_os-support_solaris_solaris-amd64.S) = 088a3118deb7567194e08dd46e34cb6edba38400
 SHA1 (patch-hw_xfree86_os-support_xf86_OSproc.h) = e1c049857893d2f050d5fb297a3e8ef86f0b1d7e
 SHA1 (patch-hw_xfree86_os_support_bus_xf86Sbus.h) = 0e0a243b737f8f762c9f8f24a2265d1b6aefb544
 SHA1 (patch-hw_xfree86_sdksyms.sh) = c403149ad35ffb70ee44f70de94b4497b751c118
diff --git a/modular-xorg-server-dfbsd/options.mk b/modular-xorg-server-dfbsd/options.mk
index 5cfc466b05..32dc952d2f 100644
--- a/modular-xorg-server-dfbsd/options.mk
+++ b/modular-xorg-server-dfbsd/options.mk
@@ -1,22 +1,22 @@
-# $NetBSD: options.mk,v 1.17 2017/02/21 14:56:14 wiz Exp $
+# $NetBSD: options.mk,v 1.18 2018/03/07 11:57:38 wiz Exp $
 
 PKG_OPTIONS_VAR=	PKG_OPTIONS.modular-xorg-server
 PKG_SUPPORTED_OPTIONS=	inet6 debug dtrace
-PKG_SUPPORTED_OPTIONS+=	devd
 PKG_SUGGESTED_OPTIONS=	inet6
+
+PKG_SUPPORTED_OPTIONS+=	devd
+.if ${OPSYS} == "FreeBSD" || ${OPSYS} == "DragonFly"
+PKG_SUGGESTED_OPTIONS+= devd
+.endif
+
 .if ${X11_TYPE} == "modular"
-PKG_SUPPORTED_OPTIONS+=	dri dri3
+PKG_SUPPORTED_OPTIONS+=	dri
 PKG_SUGGESTED_OPTIONS+=	dri
+PKG_SUPPORTED_OPTIONS+=	dri3
+# dri3 requires kernel support for dma_buf
+.if ${OPSYS} == "Linux"
 PKG_SUGGESTED_OPTIONS+=	dri3
 .endif
-
-# dri3 requires kernel support for dma_buf
-# .if ${OPSYS} == "Linux"
-# PKG_SUGGESTED_OPTIONS+=	dri3
-# .endif
-
-.if ${OPSYS} == "FreeBSD" || ${OPSYS} == "DragonFly"
-PKG_SUGGESTED_OPTIONS+=	devd
 .endif
 
 .include "../../mk/bsd.options.mk"
@@ -26,13 +26,12 @@ PLIST_VARS+=		dri3
 
 .if !empty(PKG_OPTIONS:Mdri)
 
-.  if !empty(PKG_OPTIONS:Mdri3)
+.if !empty(PKG_OPTIONS:Mdri3)
 CONFIGURE_ARGS+=	--enable-dri3
 PLIST.dri3=		yes
-.include "../../x11/xorgproto/buildlink3.mk"
-.  else
+.else
 CONFIGURE_ARGS+=	--disable-dri3
-.  endif
+.endif
 
 .include "../../graphics/libepoxy/buildlink3.mk"
 BUILDLINK_API_DEPENDS.MesaLib+=	MesaLib>=11
@@ -85,7 +84,7 @@ CONFIGURE_ARGS+=	--without-dtrace
 
 .if !empty(PKG_OPTIONS:Mdevd)
 SUBST_CLASSES+=			devd_config
-SUBST_STAGE.devd_config=	pre-build
+SUBST_STAGE.devd_config=	post-configure	
 SUBST_MESSAGE.devd_config=	Patching config/Makefile for devd
 SUBST_FILES.devd_config+=	config/Makefile
 SUBST_SED.devd_config+=		-e 's|config\.c|config.c devd.c|g'
diff --git a/modular-xorg-server-dfbsd/patches/patch-Xi_sendexev.c b/modular-xorg-server-dfbsd/patches/patch-Xi_sendexev.c
deleted file mode 100644
index 385e557594..0000000000
--- a/modular-xorg-server-dfbsd/patches/patch-Xi_sendexev.c
+++ /dev/null
@@ -1,65 +0,0 @@
-$NetBSD: patch-Xi_sendexev.c,v 1.3 2017/07/28 21:10:00 wiz Exp $
-
-CVE-2017-10971 and CVE-2017-10972: apply fixes to the event loop from
-
-   https://cgit.freedesktop.org/xorg/xserver/commit/?id=ba336b24052122b136486961c82deac76bbde455
-   https://cgit.freedesktop.org/xorg/xserver/commit/?id=8caed4df36b1f802b4992edcfd282cbeeec35d9d
-   https://cgit.freedesktop.org/xorg/xserver/commit/?id=215f894965df5fb0bb45b107d84524e700d2073c
-   https://cgit.freedesktop.org/xorg/xserver/commit/?id=05442de962d3dc624f79fc1a00eca3ffc5489ced
-
---- Xi/sendexev.c.orig	2017-03-15 18:05:25.000000000 +0000
-+++ Xi/sendexev.c
-@@ -78,7 +78,7 @@ SProcXSendExtensionEvent(ClientPtr clien
- {
-     CARD32 *p;
-     int i;
--    xEvent eventT;
-+    xEvent eventT = { .u.u.type = 0 };
-     xEvent *eventP;
-     EventSwapPtr proc;
- 
-@@ -95,9 +95,17 @@ SProcXSendExtensionEvent(ClientPtr clien
- 
-     eventP = (xEvent *) &stuff[1];
-     for (i = 0; i < stuff->num_events; i++, eventP++) {
-+        if (eventP->u.u.type == GenericEvent) {
-+            client->errorValue = eventP->u.u.type;
-+            return BadValue;
-+        }
-+
-         proc = EventSwapVector[eventP->u.u.type & 0177];
--        if (proc == NotImplemented)     /* no swapping proc; invalid event type? */
-+        /* no swapping proc; invalid event type? */
-+        if (proc == NotImplemented) {
-+            client->errorValue = eventP->u.u.type;
-             return BadValue;
-+        }
-         (*proc) (eventP, &eventT);
-         *eventP = eventT;
-     }
-@@ -117,7 +125,7 @@ SProcXSendExtensionEvent(ClientPtr clien
- int
- ProcXSendExtensionEvent(ClientPtr client)
- {
--    int ret;
-+    int ret, i;
-     DeviceIntPtr dev;
-     xEvent *first;
-     XEventClass *list;
-@@ -141,10 +149,12 @@ ProcXSendExtensionEvent(ClientPtr client
-     /* The client's event type must be one defined by an extension. */
- 
-     first = ((xEvent *) &stuff[1]);
--    if (!((EXTENSION_EVENT_BASE <= first->u.u.type) &&
--          (first->u.u.type < lastEvent))) {
--        client->errorValue = first->u.u.type;
--        return BadValue;
-+    for (i = 0; i < stuff->num_events; i++) {
-+        if (!((EXTENSION_EVENT_BASE <= first[i].u.u.type) &&
-+            (first[i].u.u.type < lastEvent))) {
-+            client->errorValue = first[i].u.u.type;
-+            return BadValue;
-+        }
-     }
- 
-     list = (XEventClass *) (first + stuff->num_events);
diff --git a/modular-xorg-server-dfbsd/patches/patch-config_devd.c b/modular-xorg-server-dfbsd/patches/patch-config_devd.c
index fa0ab677cc..0801591b9f 100644
--- a/modular-xorg-server-dfbsd/patches/patch-config_devd.c
+++ b/modular-xorg-server-dfbsd/patches/patch-config_devd.c
@@ -1,12 +1,10 @@
 $NetBSD$
 
-devd support to detect devices from FreeBSD ports / DragonFly dports
+From FreeBSD ports / DragonFly dports x11-servers/xorg-server 1.18.4.
 
-Further fix to use SetNotifyFd / RemoveNotifyFd
-
---- config/devd.c.orig	2017-02-27 17:13:49.368381000 +0000
+--- config/devd.c.orig	2018-01-06 18:38:25.992174000 +0000
 +++ config/devd.c
-@@ -0,0 +1,571 @@
+@@ -0,0 +1,643 @@
 +/*
 + * Copyright (c) 2012 Baptiste Daroussin
 + * Copyright (c) 2013, 2014 Alex Kozlov
@@ -66,8 +64,9 @@ Further fix to use SetNotifyFd / RemoveNotifyFd
 +
 +#define DEVD_EVENT_ADD		'+'
 +#define DEVD_EVENT_REMOVE	'-'
++#define DEVD_EVENT_NOTIFY	'!'
 +
-+#define RECONNECT_DELAY		5 * 1000
++#define RECONNECT_DELAY		(5 * 1000)
 +
 +static int sock_devd;
 +static bool is_console_kbd = false;
@@ -112,6 +111,7 @@ Further fix to use SetNotifyFd / RemoveNotifyFd
 +
 +	if (ret == 0 && len > 0) {
 +		snprintf(devname, devname_len, "%s%i", device->driver, unit);
++		DebugF("[config/devd]: sysctl_exists: true for sysctlname (%s), devname (%s)\n", sysctlname, devname);
 +		return true;
 +	}
 +
@@ -138,6 +138,7 @@ Further fix to use SetNotifyFd / RemoveNotifyFd
 +	free(devpath);
 +
 +	if (ret == 0) {
++		DebugF("[config/devd]: devpath_exists true for devpath (%s)\n", devpath);
 +		strncpy(devname, device->driver, devname_len);
 +		return true;
 +	}
@@ -184,6 +185,8 @@ Further fix to use SetNotifyFd / RemoveNotifyFd
 +	int i;
 +	int fd;
 +
++	DebugF("[config/devd]: begin device_added: devname (%s)\n", devname);
++
 +	for (i = 0; hw_types[i].driver != NULL; i++) {
 +		size_t len;
 +
@@ -199,6 +202,8 @@ Further fix to use SetNotifyFd / RemoveNotifyFd
 +	if (hw_types[i].driver == NULL || hw_types[i].xdriver == NULL) {
 +		LogMessage(X_INFO, "config/devd: ignoring device %s\n",
 +				devname);
++		DebugF("[config/devd]: ignoring device %s\n",
++				devname);
 +		return;
 +	}
 +
@@ -206,10 +211,13 @@ Further fix to use SetNotifyFd / RemoveNotifyFd
 +	if (is_kbdmux && is_console_kbd && hw_types[i].flag & ATTR_KEYBOARD) {
 +		LogMessage(X_INFO, "config/devd: kbdmux is enabled, ignoring device %s\n",
 +				devname);
++		DebugF("[config/devd]: kbdmux is enabled, ignoring device %s\n",
++				devname);
 +		return;
 +	}
 +
 +	snprintf(path, sizeof(path), "/dev/%s", devname);
++	DebugF("[config/devd]: device_added: devname full path (%s)\n", path);
 +
 +	options = input_option_new(NULL, "_source", "server/devd");
 +	if (!options)
@@ -217,11 +225,14 @@ Further fix to use SetNotifyFd / RemoveNotifyFd
 +
 +	snprintf(sysctlname, sizeof(sysctlname), "dev.%s.%s.%%desc",
 +	    hw_types[i].driver, devname + strlen(hw_types[i].driver));
++	DebugF("[config/devd]: device_added: try sysctl name (%s)\n", sysctlname);
 +	vendor = sysctl_get_str(sysctlname);
 +	if (vendor == NULL) {
++		DebugF("[config/devd]: device_added: input_option_new([name], devname (%s))\n", devname);
 +		options = input_option_new(options, "name", devname);
 +	}
 +	else {
++		DebugF("[config/devd]: device_added: read full vendor (%s)\n", vendor);
 +		if ((walk = strchr(vendor, ' ')) != NULL) {
 +			walk[0] = '\0';
 +			walk++;
@@ -232,10 +243,12 @@ Further fix to use SetNotifyFd / RemoveNotifyFd
 +
 +		attrs.vendor = strdup(vendor);
 +		if (product) {
++			DebugF("[config/devd]: device_added: input_option_new([name], product (%s))\n", product);
 +			attrs.product = strdup(product);
 +			options = input_option_new(options, "name", product);
 +		}
 +		else
++			DebugF("[config/devd]: device_added: input_option_new([name], [(unnamed)])\n");
 +			options = input_option_new(options, "name", "(unnamed)");
 +
 +		free(vendor);
@@ -245,9 +258,11 @@ Further fix to use SetNotifyFd / RemoveNotifyFd
 +	attrs.usb_id = NULL;
 +	attrs.device = strdup(path);
 +	options = input_option_new(options, "driver", hw_types[i].xdriver);
++	DebugF("[config/devd]: device_added: input_option_new ([driver], (%s))\n", hw_types[i].xdriver);
 +
 +	fd = open(path, O_RDONLY);
-+	if (fd > 0) {
++	if (fd >= 0) {
++		DebugF("[config/devd]: device_added: input_option_new ([device], (%s)), fd (%d)\n", path, fd);
 +		close(fd);
 +		options = input_option_new(options, "device", path);
 +	}
@@ -255,6 +270,8 @@ Further fix to use SetNotifyFd / RemoveNotifyFd
 +		if (attrs.flags & ~ATTR_KEYBOARD) {
 +			LogMessage(X_INFO, "config/devd: device %s already opened\n",
 +					 path);
++			DebugF("[config/devd]: device_added: device (%s) already opened: flags (0x%x), fd (%d)\n",
++					 path, attrs.flags, fd);
 +
 +			/*
 +			 * Fail if cannot open device, it breaks AllowMouseOpenFail,
@@ -271,9 +288,12 @@ Further fix to use SetNotifyFd / RemoveNotifyFd
 +			LogMessage(X_WARNING, "config/devd: console keyboard is "
 +					"already added, ignoring %s (%s)\n",
 +					attrs.product, path);
++			DebugF("[config/devd]: device_added: console keyboard is "
++					"already added, ignoring %s, path (%s): fd (%d)\n",
++					attrs.product, path, fd);
 +			goto unwind;
 +		}
-+		else
++		else {
 +			/*
 +			 * Don't pass "device" option if the keyboard is already
 +			 * attached to the console (ie. open() fails).
@@ -281,7 +301,11 @@ Further fix to use SetNotifyFd / RemoveNotifyFd
 +			 * Prevent any other attached to console keyboards being
 +			 * processed. There can be only one such device.
 +			 */
++			DebugF("[config/devd]: device_added: keyboard already attached to console "
++					"is_console_kbd = true, ignoring %s, path (%s): fd (%d)\n",
++					attrs.product, path, fd);
 +			is_console_kbd = true;
++		}
 +	}
 +
 +	if (asprintf(&config_info, "devd:%s", devname) == -1) {
@@ -292,14 +316,22 @@ Further fix to use SetNotifyFd / RemoveNotifyFd
 +	if (device_is_duplicate(config_info)) {
 +		LogMessage(X_WARNING, "config/devd: device %s (%s) already added. "
 +				"ignoring\n", attrs.product, path);
++		DebugF("[config/devd]: device %s (%s) already added. "
++				"ignoring\n", attrs.product, path);
 +		goto unwind;
 +	}
 +
++	DebugF("[config/devd]: device_added: input_option_new ([config_info], (%s))\n", config_info);
 +	options = input_option_new(options, "config_info", config_info);
 +	LogMessage(X_INFO, "config/devd: adding input device %s (%s)\n",
 +			attrs.product, path);
++	DebugF("[config/devd]: device_added: before   NewInputDeviceRequest for device %s (%s)\n",
++			attrs.product, path);
 +
 +	NewInputDeviceRequest(options, &attrs, &dev);
++	
++	DebugF("[config/devd]: device_added: finished NewInputDeviceRequest for device %s (%s)\n",
++			attrs.product, path);
 +
 +unwind:
 +	free(config_info);
@@ -315,6 +347,8 @@ Further fix to use SetNotifyFd / RemoveNotifyFd
 +{
 +	char *config_info;
 +
++	DebugF("[config/devd]: removing device (%s)\n", devname);
++
 +	if (asprintf(&config_info, "devd:%s", devname) == -1)
 +		return;
 +
@@ -332,17 +366,20 @@ Further fix to use SetNotifyFd / RemoveNotifyFd
 +	int fd;
 +
 +	fd = open(device, O_RDONLY);
++	DebugF("[config/devd]: is_kbdmux_enabled: device (%s) opened, fd (%d)\n", device, fd);
 +
 +	if (fd < 0)
 +		return false;
 +
 +	if (ioctl(fd, KDGKBINFO, &info) == -1) {
++		DebugF("[config/devd]: is_kbdmux_enabled: ioctl KDGKBINFO failed (%s)\n", strerror(errno));
 +		close(fd);
 +		return false;
 +	}
 +
 +	close(fd);
 +
++	DebugF("[config/devd]: is_kbdmux_enabled: info.kb_name (%s)\n", info.kb_name);
 +	if (!strncmp(info.kb_name, "kbdmux", 6))
 +		return true;
 +
@@ -352,6 +389,9 @@ Further fix to use SetNotifyFd / RemoveNotifyFd
 +static void
 +disconnect_devd(int sock)
 +{
++	LogMessage(X_INFO, "config/devd: disconnect socket (%d)\n", sock);
++	DebugF("[config/devd]: disconnect socket (%d)\n", sock);
++
 +	if (sock >= 0) {
 +		RemoveNotifyFd(sock);
 +		close(sock);
@@ -359,7 +399,7 @@ Further fix to use SetNotifyFd / RemoveNotifyFd
 +}
 +
 +static void
-+devdInputHandlerNotify(int sock, int read, void *data);
++socket_handler(int sock, int ready, void *data);
 +
 +static int
 +connect_devd(void)
@@ -367,22 +407,30 @@ Further fix to use SetNotifyFd / RemoveNotifyFd
 +	struct sockaddr_un devd;
 +	int sock;
 +
++	DebugF("[config/devd]: connecting ... \n");
++
 +	sock = socket(AF_UNIX, SOCK_STREAM, 0);
 +	if (sock < 0) {
-+		LogMessage(X_ERROR, "config/devd: fail opening stream socket\n");
++		LogMessage(X_ERROR, "[config/devd]: failed opening stream socket: %s\n", strerror(errno));
++		DebugF("[config/devd]: connect_devd: failed opening stream socket: %s\n", strerror(errno));
 +		return -1;
 +	}
 +
++	DebugF("[config/devd]: opened stream socket (%d)\n", sock);
++
 +	devd.sun_family = AF_UNIX;
 +	strlcpy(devd.sun_path, DEVD_SOCK_PATH, sizeof(devd.sun_path));
 +
 +	if (connect(sock, (struct sockaddr *) &devd, sizeof(devd)) < 0) {
 +		close(sock);
-+		LogMessage(X_ERROR, "config/devd: fail to connect to devd\n");
++		LogMessage(X_ERROR, "[config/devd]: failed to connect to devd: %s\n", strerror(errno));
++		DebugF("[config/devd]: connect_devd: failed to connect to devd: %s\n", strerror(errno));
 +		return -1;
 +	}
 +
-+	SetNotifyFd(sock, devdInputHandlerNotify, X_NOTIFY_READ, NULL);
++	DebugF("[config/devd]: connected to devd, sock (%d), pid file (%s)\n", sock, DEVD_SOCK_PATH);
++
++	SetNotifyFd(sock, socket_handler, X_NOTIFY_READ, NULL);
 +
 +	return	sock;
 +}
@@ -392,13 +440,15 @@ Further fix to use SetNotifyFd / RemoveNotifyFd
 +{
 +	int newsock;
 +
-+	if ((newsock = connect_devd()) > 0) {
++	if ((newsock = connect_devd()) >= 0) {
 +		sock_devd = newsock;
 +		TimerFree(rtimer);
 +		rtimer = NULL;
 +		LogMessage(X_INFO, "config/devd: reopening devd socket\n");
++		DebugF("[config/devd]: reconnect_handler: RECONNECTED using socket (%d)\n", sock_devd);
 +		return 0;
 +	}
++	DebugF("[config/devd]: reconnect_handler FAILED to reconnect returned (%d)\n", newsock);
 +
 +	/* Try again after RECONNECT_DELAY */
 +	return RECONNECT_DELAY;
@@ -411,6 +461,8 @@ Further fix to use SetNotifyFd / RemoveNotifyFd
 +	ssize_t ret, cap, sz = 0;
 +	char c;
 +
++	*out = NULL;
++
 +	cap = 1024;
 +	buf = malloc(cap * sizeof(char));
 +	if (!buf)
@@ -428,6 +480,7 @@ Further fix to use SetNotifyFd / RemoveNotifyFd
 +			disconnect_devd(sock_devd);
 +			rtimer = TimerSet(NULL, 0, 1, reconnect_handler, NULL);
 +			LogMessage(X_WARNING, "config/devd: devd socket is lost\n");
++			DebugF("[config/devd]: socket_getline: EOF devd socket (%d) is LOST\n", sock_devd);
 +			free(buf);
 +			return -1;
 +		}
@@ -489,13 +542,22 @@ Further fix to use SetNotifyFd / RemoveNotifyFd
 +#endif
 +
 +static void
-+devdInputHandlerNotify(int sock, int read, void *data)
++socket_handler(int sock, int ready, void *data)
 +{
 +	char *line = NULL;
 +	char *walk;
++	ssize_t sz;
 +
-+	if (socket_getline(sock, &line) < 0)
++	DebugF("[config/devd]: socket_handler: sock_devd (%d), sock (%d), ready (%d)\n", sock_devd, sock, ready);
++	
++	sz = socket_getline(sock_devd, &line);
++	if (sz < 0)
 +		return;
++	if (sz == 0) {
++		free(line);
++		return;
++	}
++	DebugF("[config/devd]: socket_handler: socket_getline (%s)\n", line);
 +
 +	walk = strchr(line + 1, ' ');
 +	if (walk != NULL)
@@ -503,11 +565,16 @@ Further fix to use SetNotifyFd / RemoveNotifyFd
 +
 +	switch (*line) {
 +	case DEVD_EVENT_ADD:
++		DebugF("[config/devd]: socket_handler: DEVD_EVENT_ADD line (%s)\n", line);
 +		device_added(line + 1);
 +		break;
 +	case DEVD_EVENT_REMOVE:
++		DebugF("[config/devd]: socket_handler: DEVD_EVENT_REMOVE line (%s)\n", line);
 +		device_removed(line + 1);
 +		break;
++	case DEVD_EVENT_NOTIFY:
++		DebugF("[config/devd]: socket_handler: DEVD_EVENT_NOTIFY line (%s)\n", line);
++		break;
 +	default:
 +		break;
 +	}
@@ -528,6 +595,7 @@ Further fix to use SetNotifyFd / RemoveNotifyFd
 +	int i, j;
 +
 +	LogMessage(X_INFO, "config/devd: probing input devices...\n");
++	DebugF("[config/devd]: config_devd_init: probing input devices...\n");
 +
 +	/*
 +	 * Add fake keyboard and give up on keyboards management
@@ -554,6 +622,7 @@ Further fix to use SetNotifyFd / RemoveNotifyFd
 +#if 0
 +	RegisterBlockAndWakeupHandlers(block_handler, wakeup_handler, NULL);
 +#endif
++	DebugF("[config/devd]: config_devd_init: devices probed, sock_devd (%d)\n", sock_devd);
 +
 +	return 1;
 +}
@@ -562,6 +631,7 @@ Further fix to use SetNotifyFd / RemoveNotifyFd
 +config_devd_fini(void)
 +{
 +	LogMessage(X_INFO, "config/devd: terminating backend...\n");
++	DebugF("[config/devd]: terminating backend...\n");
 +
 +	if (rtimer) {
 +		TimerFree(rtimer);
diff --git a/modular-xorg-server-dfbsd/patches/patch-configure b/modular-xorg-server-dfbsd/patches/patch-configure
index 6d4e33aed5..5cb1a5d428 100644
--- a/modular-xorg-server-dfbsd/patches/patch-configure
+++ b/modular-xorg-server-dfbsd/patches/patch-configure
@@ -5,9 +5,9 @@ Use USE_AMD64_IOPL (actually x86_64_iopl) on NetBSD/amd64.
 
 for netbsd, force pass pthread configure checks (pthread not needed)
 
---- configure.orig	2015-02-10 22:49:52.000000000 +0000
+--- configure.orig	2017-12-20 20:32:47.000000000 +0000
 +++ configure
-@@ -23235,7 +23235,7 @@ $as_echo "#define USE_DEV_IO 1" >>confde
+@@ -23305,7 +23305,7 @@ $as_echo "#define USE_DEV_IO 1" >>confde
  $as_echo "#define USE_DEV_IO 1" >>confdefs.h
   ;;
  		*netbsd*)
@@ -16,7 +16,7 @@ for netbsd, force pass pthread configure checks (pthread not needed)
  
  				SYS_LIBS=-lx86_64
  				;;
-@@ -25079,7 +25079,8 @@ case ${host_os} in
+@@ -25149,7 +25149,8 @@ case ${host_os} in
  	netbsd*)
  	# use libc stubs, don't link against libpthread, to allow
  	# dynamic loading
diff --git a/modular-xorg-server-dfbsd/patches/patch-dix_events.c b/modular-xorg-server-dfbsd/patches/patch-dix_events.c
deleted file mode 100644
index 5962da4455..0000000000
--- a/modular-xorg-server-dfbsd/patches/patch-dix_events.c
+++ /dev/null
@@ -1,24 +0,0 @@
-$NetBSD: patch-dix_events.c,v 1.1 2017/07/28 21:10:00 wiz Exp $
-
-CVE-2017-10971 and CVE-2017-10972: apply fixes to the event loop from
-
-   https://cgit.freedesktop.org/xorg/xserver/commit/?id=ba336b24052122b136486961c82deac76bbde455
-   https://cgit.freedesktop.org/xorg/xserver/commit/?id=8caed4df36b1f802b4992edcfd282cbeeec35d9d
-   https://cgit.freedesktop.org/xorg/xserver/commit/?id=215f894965df5fb0bb45b107d84524e700d2073c
-   https://cgit.freedesktop.org/xorg/xserver/commit/?id=05442de962d3dc624f79fc1a00eca3ffc5489ced
-
---- dix/events.c.orig	2017-03-15 18:05:25.000000000 +0000
-+++ dix/events.c
-@@ -5366,6 +5366,12 @@ ProcSendEvent(ClientPtr client)
-         client->errorValue = stuff->event.u.u.type;
-         return BadValue;
-     }
-+    /* Generic events can have variable size, but SendEvent request holds
-+       exactly 32B of event data. */
-+    if (stuff->event.u.u.type == GenericEvent) {
-+        client->errorValue = stuff->event.u.u.type;
-+        return BadValue;
-+    }
-     if (stuff->event.u.u.type == ClientMessage &&
-         stuff->event.u.u.detail != 8 &&
-         stuff->event.u.u.detail != 16 && stuff->event.u.u.detail != 32) {
diff --git a/modular-xorg-server-dfbsd/patches/patch-dix_swapreq.c b/modular-xorg-server-dfbsd/patches/patch-dix_swapreq.c
deleted file mode 100644
index 8c1a2efde5..0000000000
--- a/modular-xorg-server-dfbsd/patches/patch-dix_swapreq.c
+++ /dev/null
@@ -1,25 +0,0 @@
-$NetBSD: patch-dix_swapreq.c,v 1.1 2017/07/28 21:10:00 wiz Exp $
-
-CVE-2017-10971 and CVE-2017-10972: apply fixes to the event loop from
-
-   https://cgit.freedesktop.org/xorg/xserver/commit/?id=ba336b24052122b136486961c82deac76bbde455
-   https://cgit.freedesktop.org/xorg/xserver/commit/?id=8caed4df36b1f802b4992edcfd282cbeeec35d9d
-   https://cgit.freedesktop.org/xorg/xserver/commit/?id=215f894965df5fb0bb45b107d84524e700d2073c
-   https://cgit.freedesktop.org/xorg/xserver/commit/?id=05442de962d3dc624f79fc1a00eca3ffc5489ced
-
---- dix/swapreq.c.orig	2017-03-15 18:05:25.000000000 +0000
-+++ dix/swapreq.c
-@@ -292,6 +292,13 @@ SProcSendEvent(ClientPtr client)
-     swapl(&stuff->destination);
-     swapl(&stuff->eventMask);
- 
-+    /* Generic events can have variable size, but SendEvent request holds
-+       exactly 32B of event data. */
-+    if (stuff->event.u.u.type == GenericEvent) {
-+        client->errorValue = stuff->event.u.u.type;
-+        return BadValue;
-+    }
-+
-     /* Swap event */
-     proc = EventSwapVector[stuff->event.u.u.type & 0177];
-     if (!proc || proc == NotImplemented)        /* no swapping proc; invalid event type? */
diff --git a/modular-xorg-server-dfbsd/patches/patch-glx_glxscreens.c b/modular-xorg-server-dfbsd/patches/patch-glx_glxscreens.c
new file mode 100644
index 0000000000..8e1545d3df
--- /dev/null
+++ b/modular-xorg-server-dfbsd/patches/patch-glx_glxscreens.c
@@ -0,0 +1,26 @@
+$NetBSD$
+
+https://cgit.freedesktop.org/xorg/xserver/commit/?id=c2954b16c8730c7ed8441fd8dba25900f3aed265
+
+glx: do not pick sRGB config for 32-bit RGBA visual
+This fixes blending issues seen with kwin and gnome-shell when
+32bit visual has sRGB capability set.
+
+Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=103699
+Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=103646
+Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=103655
+
+--- glx/glxscreens.c.orig	2017-12-20 20:32:33.000000000 +0000
++++ glx/glxscreens.c
+@@ -275,6 +275,11 @@ pickFBConfig(__GLXscreen * pGlxScreen, V
+         /* If it's the 32-bit RGBA visual, demand a 32-bit fbconfig. */
+         if (visual->nplanes == 32 && config->rgbBits != 32)
+             continue;
++        /* If it's the 32-bit RGBA visual, do not pick sRGB capable config.
++         * This can cause issues with compositors that are not sRGB aware.
++         */
++        if (visual->nplanes == 32 && config->sRGBCapable == GL_TRUE)
++            continue;
+         /* Can't use the same FBconfig for multiple X visuals.  I think. */
+         if (config->visualID != 0)
+             continue;
diff --git a/modular-xorg-server-dfbsd/patches/patch-hw_xfree86_common_xf86AutoConfig.c b/modular-xorg-server-dfbsd/patches/patch-hw_xfree86_common_xf86AutoConfig.c
new file mode 100644
index 0000000000..977de9324f
--- /dev/null
+++ b/modular-xorg-server-dfbsd/patches/patch-hw_xfree86_common_xf86AutoConfig.c
@@ -0,0 +1,27 @@
+$NetBSD$
+
+From FreeBSD ports for x11-servers/xorg-server.
+
+--- hw/xfree86/common/xf86AutoConfig.c.orig	2017-12-20 20:32:33.000000000 +0000
++++ hw/xfree86/common/xf86AutoConfig.c
+@@ -276,7 +276,7 @@ listPossibleVideoDrivers(char *matches[]
+         i += xf86PciMatchDriver(&matches[i], nmatches - i);
+ #endif
+ 
+-#if defined(__linux__)
++#if defined(__linux__) || defined(__FreeBSD__) || defined(__DragonFly__)
+     matches[i++] = xnfstrdup("modesetting");
+ #endif
+ 
+@@ -285,8 +285,10 @@ listPossibleVideoDrivers(char *matches[]
+     if (i < (nmatches - 1)) {
+ #if !defined(__linux__) && defined(__sparc__)
+         matches[i++] = xnfstrdup("wsfb");
+-#else
++#elif defined(__linux__)
+         matches[i++] = xnfstrdup("fbdev");
++#elif defined(__FreeBSD__)
++        matches[i++] = xnfstrdup("scfb");
+ #endif
+     }
+ #endif                          /* !__sun */
diff --git a/modular-xorg-server-dfbsd/patches/patch-hw_xfree86_common_xf86Xinput.c b/modular-xorg-server-dfbsd/patches/patch-hw_xfree86_common_xf86Xinput.c
index 01d708e8bf..3b6d76d78a 100644
--- a/modular-xorg-server-dfbsd/patches/patch-hw_xfree86_common_xf86Xinput.c
+++ b/modular-xorg-server-dfbsd/patches/patch-hw_xfree86_common_xf86Xinput.c
@@ -1,10 +1,12 @@
 $NetBSD$
 
-devd support to detect devices from FreeBSD ports / DragonFly dports
+From FreeBSD ports / DragonFly dports x11-servers/xorg-server 1.18.4.
 
---- hw/xfree86/common/xf86Xinput.c.orig	2017-01-04 21:32:10.000000000 +0000
+devd support
+
+--- hw/xfree86/common/xf86Xinput.c.orig	2017-12-20 20:32:33.000000000 +0000
 +++ hw/xfree86/common/xf86Xinput.c
-@@ -871,7 +871,7 @@ xf86NewInputDevice(InputInfoPtr pInfo, D
+@@ -874,7 +874,7 @@ xf86NewInputDevice(InputInfoPtr pInfo, D
  {
      InputDriverPtr drv = NULL;
      DeviceIntPtr dev = NULL;
@@ -13,7 +15,7 @@ devd support to detect devices from FreeBSD ports / DragonFly dports
      int rval;
      char *path = NULL;
  
-@@ -1034,6 +1034,7 @@ NewInputDeviceRequest(InputOption *optio
+@@ -1037,6 +1037,7 @@ NewInputDeviceRequest(InputOption *optio
          if (strcmp(key, "_source") == 0 &&
              (strcmp(value, "server/hal") == 0 ||
               strcmp(value, "server/udev") == 0 ||
diff --git a/modular-xorg-server-dfbsd/patches/patch-hw_xfree86_os-support_solaris_solaris-amd64.S b/modular-xorg-server-dfbsd/patches/patch-hw_xfree86_os-support_solaris_solaris-amd64.S
new file mode 100644
index 0000000000..6ec5b859e2
--- /dev/null
+++ b/modular-xorg-server-dfbsd/patches/patch-hw_xfree86_os-support_solaris_solaris-amd64.S
@@ -0,0 +1,62 @@
+$NetBSD: patch-hw_xfree86_os-support_solaris_solaris-amd64.S,v 1.1 2018/01/25 15:06:10 jperkin Exp $
+
+Make assembly work with clang.
+
+--- hw/xfree86/os-support/solaris/solaris-amd64.S.orig	2017-12-20 20:32:33.000000000 +0000
++++ hw/xfree86/os-support/solaris/solaris-amd64.S
+@@ -1,3 +1,4 @@
++#if 0
+ / Copyright (c) 2005, Oracle and/or its affiliates. All rights reserved.
+ / 
+ / Permission is hereby granted, free of charge, to any person obtaining a
+@@ -18,6 +19,7 @@
+ / LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ / FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
+ / DEALINGS IN THE SOFTWARE.
++#endif
+ 
+ #ifdef INLINE_ASM
+ #define FUNCTION_START(f,n)	.inline f,n
+@@ -32,36 +34,36 @@
+ 	FUNCTION_START(inb,4)
+ 	movq	%rdi, %rdx
+ 	xorq    %rax, %rax
+-	inb	(%dx)
++	inb	%dx
+ 	FUNCTION_END(inb)
+ 
+ 	FUNCTION_START(inw,4)
+ 	movq	%rdi, %rdx
+ 	xorq    %rax, %rax
+-	inw	(%dx)
++	inw	%dx
+ 	FUNCTION_END(inw)
+ 
+ 	FUNCTION_START(inl,4)
+ 	movq	%rdi, %rdx
+ 	xorq    %rax, %rax
+-	inl	(%dx)
++	inl	%dx
+ 	FUNCTION_END(inl)
+ 
+ 	FUNCTION_START(outb,8)
+ 	movq	%rdi, %rdx
+ 	movq    %rsi, %rax
+-	outb	(%dx)
++	outb	%dx
+ 	FUNCTION_END(outb)
+ 
+ 	FUNCTION_START(outw,8)
+ 	movq	%rdi, %rdx
+ 	movq    %rsi, %rax
+-	outw	(%dx)
++	outw	%dx
+ 	FUNCTION_END(outw)
+ 
+ 	FUNCTION_START(outl,8)
+ 	movq	%rdi, %rdx
+ 	movq    %rsi, %rax
+-	outl	(%dx)
++	outl	%dx
+ 	FUNCTION_END(outl)
+ 



Home | Main Index | Thread Index | Old Index