Tue May 8 11:20:13 2012 UTC ()
allow use of the wsmouse protocol on NetBSD, bump PKGREV


(drochner)
diff -r1.13 -r1.14 pkgsrc/x11/xf86-input-mouse/Makefile
diff -r1.9 -r1.10 pkgsrc/x11/xf86-input-mouse/distinfo
diff -r1.1 -r1.2 pkgsrc/x11/xf86-input-mouse/patches/patch-ac

cvs diff -r1.13 -r1.14 pkgsrc/x11/xf86-input-mouse/Makefile (expand / switch to unified diff)

--- pkgsrc/x11/xf86-input-mouse/Makefile 2012/05/06 20:51:24 1.13
+++ pkgsrc/x11/xf86-input-mouse/Makefile 2012/05/08 11:20:13 1.14
@@ -1,16 +1,17 @@ @@ -1,16 +1,17 @@
1# $NetBSD: Makefile,v 1.13 2012/05/06 20:51:24 wiz Exp $ 1# $NetBSD: Makefile,v 1.14 2012/05/08 11:20:13 drochner Exp $
2 2
3DISTNAME= xf86-input-mouse-1.7.2 3DISTNAME= xf86-input-mouse-1.7.2
 4PKGREVISION= 1
4CATEGORIES= x11 5CATEGORIES= x11
5MASTER_SITES= ${MASTER_SITE_XORG:=driver/} 6MASTER_SITES= ${MASTER_SITE_XORG:=driver/}
6EXTRACT_SUFX= .tar.bz2 7EXTRACT_SUFX= .tar.bz2
7 8
8MAINTAINER= joerg@NetBSD.org 9MAINTAINER= joerg@NetBSD.org
9HOMEPAGE= http://xorg.freedesktop.org/ 10HOMEPAGE= http://xorg.freedesktop.org/
10COMMENT= Modular Xorg mouse driver 11COMMENT= Modular Xorg mouse driver
11 12
12PKG_DESTDIR_SUPPORT= user-destdir 13PKG_DESTDIR_SUPPORT= user-destdir
13 14
14USE_LIBTOOL= YES 15USE_LIBTOOL= YES
15GNU_CONFIGURE= YES 16GNU_CONFIGURE= YES
16USE_TOOLS+= pkg-config 17USE_TOOLS+= pkg-config

cvs diff -r1.9 -r1.10 pkgsrc/x11/xf86-input-mouse/distinfo (expand / switch to unified diff)

--- pkgsrc/x11/xf86-input-mouse/distinfo 2012/05/06 20:51:24 1.9
+++ pkgsrc/x11/xf86-input-mouse/distinfo 2012/05/08 11:20:13 1.10
@@ -1,8 +1,8 @@ @@ -1,8 +1,8 @@
1$NetBSD: distinfo,v 1.9 2012/05/06 20:51:24 wiz Exp $ 1$NetBSD: distinfo,v 1.10 2012/05/08 11:20:13 drochner Exp $
2 2
3SHA1 (xf86-input-mouse-1.7.2.tar.bz2) = 0da6390c6f3d7d636110a52f08193739929ae4ae 3SHA1 (xf86-input-mouse-1.7.2.tar.bz2) = 0da6390c6f3d7d636110a52f08193739929ae4ae
4RMD160 (xf86-input-mouse-1.7.2.tar.bz2) = 467870d6b65decc832fadf66896d613456f217cd 4RMD160 (xf86-input-mouse-1.7.2.tar.bz2) = 467870d6b65decc832fadf66896d613456f217cd
5Size (xf86-input-mouse-1.7.2.tar.bz2) = 341378 bytes 5Size (xf86-input-mouse-1.7.2.tar.bz2) = 341378 bytes
6SHA1 (patch-ab) = 632ec0e3908ccd16678a480b5ffa00dba7db640f 6SHA1 (patch-ab) = 632ec0e3908ccd16678a480b5ffa00dba7db640f
7SHA1 (patch-ac) = d32bbb082c0898e6eb6bf9dadb2af401b1e79312 7SHA1 (patch-ac) = eea2c36d6b652448996a52cf413a46cfe3accd7e
8SHA1 (patch-src_mouse.h) = 7df93c8f7ef6e054ffd252246480051490c79d7b 8SHA1 (patch-src_mouse.h) = 7df93c8f7ef6e054ffd252246480051490c79d7b

cvs diff -r1.1 -r1.2 pkgsrc/x11/xf86-input-mouse/patches/Attic/patch-ac (expand / switch to unified diff)

--- pkgsrc/x11/xf86-input-mouse/patches/Attic/patch-ac 2009/05/22 19:05:57 1.1
+++ pkgsrc/x11/xf86-input-mouse/patches/Attic/patch-ac 2012/05/08 11:20:13 1.2
@@ -1,106 +1,115 @@ @@ -1,106 +1,115 @@
1$NetBSD: patch-ac,v 1.1 2009/05/22 19:05:57 tnn Exp $ 1$NetBSD: patch-ac,v 1.2 2012/05/08 11:20:13 drochner Exp $
2 2
3Changes from NetBSD xsrc/external/mit/xorg-server/dist/\ 3Changes from NetBSD xsrc/external/mit/xorg-server/dist/\
4hw/xfree86/os-support/bsd/bsd_mouse.c 4hw/xfree86/os-support/bsd/bsd_mouse.c
5 5
6---------------------------- 6----------------------------
7revision 1.5 7revision 1.5
8date: 2009/02/09 09:49:39; author: plunky; state: Exp; lines: +16 -0 8date: 2009/02/09 09:49:39; author: plunky; state: Exp; lines: +16 -0
9add horizontal mouse-wheel functionality to USB and WSMOUSE drivers 9add horizontal mouse-wheel functionality to USB and WSMOUSE drivers
10---------------------------- 10----------------------------
11revision 1.4 11revision 1.4
12date: 2009/02/02 03:06:37; author: christos; state: Exp; lines: +7 -11 12date: 2009/02/02 03:06:37; author: christos; state: Exp; lines: +7 -11
13add a SetupMouse proc to condition the fd. Convert NetBSD's SetupAuto to 13add a SetupMouse proc to condition the fd. Convert NetBSD's SetupAuto to
14SetupMouse. 14SetupMouse.
15---------------------------- 15----------------------------
16revision 1.3 16revision 1.3
17date: 2009/01/19 00:54:29; author: christos; state: Exp; lines: +2 -1 17date: 2009/01/19 00:54:29; author: christos; state: Exp; lines: +2 -1
18fix ioctl. 18fix ioctl.
19---------------------------- 19----------------------------
20revision 1.2 20revision 1.2
21date: 2009/01/13 18:43:46; author: christos; state: Exp; lines: +25 -0 21date: 2009/01/13 18:43:46; author: christos; state: Exp; lines: +25 -0
22Set the mouse event protocol version. (untested, but head will be broken 22Set the mouse event protocol version. (untested, but head will be broken
23unless I add this). 23unless I add this).
24---------------------------- 24----------------------------
25 25
26--- src/bsd_mouse.c.orig 2009-05-19 15:12:28 +0300 26--- src/bsd_mouse.c.orig 2012-03-16 06:34:27.000000000 +0000
27+++ src/bsd_mouse.c 2009-05-19 15:13:13 +0300 27+++ src/bsd_mouse.c
28@@ -53,12 +53,15 @@ 28@@ -53,12 +53,15 @@
29  29
30 #define HUP_GENERIC_DESKTOP 0x0001 30 #define HUP_GENERIC_DESKTOP 0x0001
31 #define HUP_BUTTON 0x0009 31 #define HUP_BUTTON 0x0009
32+#define HUP_CONSUMER 0x000c 32+#define HUP_CONSUMER 0x000c
33  33
34 #define HUG_X 0x0030 34 #define HUG_X 0x0030
35 #define HUG_Y 0x0031 35 #define HUG_Y 0x0031
36 #define HUG_Z 0x0032 36 #define HUG_Z 0x0032
37 #define HUG_WHEEL 0x0038 37 #define HUG_WHEEL 0x0038
38  38
39+#define HUC_AC_PAN 0x0238 39+#define HUC_AC_PAN 0x0238
40+ 40+
41 #define HID_USAGE2(p,u) (((p) << 16) | u) 41 #define HID_USAGE2(p,u) (((p) << 16) | u)
42  42
43 /* The UMS mices have middle button as number 3 */ 43 /* The UMS mices have middle button as number 3 */
 44@@ -98,7 +101,7 @@ static int
 45 SupportedInterfaces(void)
 46 {
 47 #if defined(__NetBSD__)
 48- return MSE_SERIAL | MSE_BUS | MSE_PS2 | MSE_AUTO;
 49+ return MSE_SERIAL | MSE_BUS | MSE_PS2 | MSE_AUTO | MSE_MISC;
 50 #elif defined(__FreeBSD__) || defined(__FreeBSD_kernel__) || defined(__DragonFly__)
 51 return MSE_SERIAL | MSE_BUS | MSE_PS2 | MSE_AUTO | MSE_MISC;
 52 #else
44@@ -339,6 +342,23 @@ FindDevice(InputInfoPtr pInfo, const cha 53@@ -339,6 +342,23 @@ FindDevice(InputInfoPtr pInfo, const cha
45 } 54 }
46 #endif 55 #endif
47  56
48+#if defined(__NetBSD__) 57+#if defined(__NetBSD__)
49+static Bool 58+static Bool
50+SetupMouse(InputInfoPtr pInfo) 59+SetupMouse(InputInfoPtr pInfo)
51+{ 60+{
52+#ifdef WSCONS_SUPPORT 61+#ifdef WSCONS_SUPPORT
53+#ifdef WSMOUSEIO_SETVERSION 62+#ifdef WSMOUSEIO_SETVERSION
54+ int version = WSMOUSE_EVENT_VERSION; 63+ int version = WSMOUSE_EVENT_VERSION;
55+ if (ioctl(pInfo->fd, WSMOUSEIO_SETVERSION, &version) == -1) { 64+ if (ioctl(pInfo->fd, WSMOUSEIO_SETVERSION, &version) == -1) {
56+ xf86Msg(X_WARNING, "%s: cannot set version\n", pInfo->name); 65+ xf86Msg(X_WARNING, "%s: cannot set version\n", pInfo->name);
57+ return FALSE; 66+ return FALSE;
58+ } 67+ }
59+#endif 68+#endif
60+#endif 69+#endif
61+ return TRUE; 70+ return TRUE;
62+} 71+}
63+#endif 72+#endif
64+ 73+
65 #if (defined(__OpenBSD__) || defined(__NetBSD__)) && defined(WSCONS_SUPPORT) 74 #if (defined(__OpenBSD__) || defined(__NetBSD__)) && defined(WSCONS_SUPPORT)
66  75
67 /* Only support wsmouse configuration for now */ 76 /* Only support wsmouse configuration for now */
68@@ -496,7 +516,7 @@ typedef struct _UsbMseRec { 77@@ -473,7 +493,7 @@ typedef struct _UsbMseRec {
69 hid_item_t loc_x; /* x locator item */ 78 hid_item_t loc_x; /* x locator item */
70 hid_item_t loc_y; /* y locator item */ 79 hid_item_t loc_y; /* y locator item */
71 hid_item_t loc_z; /* z (wheel) locator item */ 80 hid_item_t loc_z; /* z (wheel) locator item */
72- hid_item_t loc_w; /* z (wheel) locator item */ 81- hid_item_t loc_w; /* z (wheel) locator item */
73+ hid_item_t loc_w; /* w (pan) locator item */ 82+ hid_item_t loc_w; /* w (pan) locator item */
74 hid_item_t loc_btn[MSE_MAXBUTTONS]; /* buttons locator items */ 83 hid_item_t loc_btn[MSE_MAXBUTTONS]; /* buttons locator items */
75 unsigned char *buffer; 84 unsigned char *buffer;
76 } UsbMseRec, *UsbMsePtr; 85 } UsbMseRec, *UsbMsePtr;
77@@ -708,6 +728,9 @@ usbPreInit(InputInfoPtr pInfo, const cha 86@@ -688,6 +708,9 @@ usbPreInit(InputInfoPtr pInfo, const cha
78 if (hid_locate(reportDesc, HID_USAGE2(HUP_GENERIC_DESKTOP, HUG_WHEEL), 87 if (hid_locate(reportDesc, HID_USAGE2(HUP_GENERIC_DESKTOP, HUG_WHEEL),
79 hid_input, &pUsbMse->loc_z, pUsbMse->iid) < 0) { 88 hid_input, &pUsbMse->loc_z, pUsbMse->iid) < 0) {
80 } 89 }
81+ if (hid_locate(reportDesc, HID_USAGE2(HUP_CONSUMER, HUC_AC_PAN), 90+ if (hid_locate(reportDesc, HID_USAGE2(HUP_CONSUMER, HUC_AC_PAN),
82+ hid_input, &pUsbMse->loc_w, pUsbMse->iid) < 0) { 91+ hid_input, &pUsbMse->loc_w, pUsbMse->iid) < 0) {
83+ } 92+ }
84 #else 93 #else
85 if (hid_locate(reportDesc, HID_USAGE2(HUP_GENERIC_DESKTOP, HUG_X), 94 if (hid_locate(reportDesc, HID_USAGE2(HUP_GENERIC_DESKTOP, HUG_X),
86 hid_input, &pUsbMse->loc_x) < 0) { 95 hid_input, &pUsbMse->loc_x) < 0) {
87@@ -720,6 +743,9 @@ usbPreInit(InputInfoPtr pInfo, const cha 96@@ -700,6 +723,9 @@ usbPreInit(InputInfoPtr pInfo, const cha
88 if (hid_locate(reportDesc, HID_USAGE2(HUP_GENERIC_DESKTOP, HUG_WHEEL), 97 if (hid_locate(reportDesc, HID_USAGE2(HUP_GENERIC_DESKTOP, HUG_WHEEL),
89 hid_input, &pUsbMse->loc_z) < 0) { 98 hid_input, &pUsbMse->loc_z) < 0) {
90 } 99 }
91+ if (hid_locate(reportDesc, HID_USAGE2(HUP_CONSUMER, HUC_AC_PAN), 100+ if (hid_locate(reportDesc, HID_USAGE2(HUP_CONSUMER, HUC_AC_PAN),
92+ hid_input, &pUsbMse->loc_w) < 0) { 101+ hid_input, &pUsbMse->loc_w) < 0) {
93+ } 102+ }
94 #endif 103 #endif
95 /* Probe for number of buttons */ 104 /* Probe for number of buttons */
96 for (i = 1; i <= MSE_MAXBUTTONS; i++) { 105 for (i = 1; i <= MSE_MAXBUTTONS; i++) {
97@@ -790,6 +816,9 @@ xf86OSMouseInit(int flags) 106@@ -772,6 +798,9 @@ OSMouseInit(int flags)
98 p->SetupAuto = SetupAuto; 107 p->SetupAuto = SetupAuto;
99 p->SetMiscRes = SetMouseRes; 108 p->SetMiscRes = SetMouseRes;
100 #endif 109 #endif
101+#if defined(__NetBSD__) 110+#if defined(__NetBSD__)
102+ p->SetupMouse = SetupMouse; 111+ p->SetupMouse = SetupMouse;
103+#endif 112+#endif
104 #if defined(__FreeBSD__) || defined(__FreeBSD_kernel__) || defined(__OpenBSD__) || defined(__DragonFly__) || defined(__NetBSD__) 113 #if defined(__FreeBSD__) || defined(__FreeBSD_kernel__) || defined(__OpenBSD__) || defined(__DragonFly__) || defined(__NetBSD__)
105 p->FindDevice = FindDevice; 114 p->FindDevice = FindDevice;
106 #endif 115 #endif