View | Details | Raw Unified | Return to bug 196978 | Differences between
and this patch

Collapse All | Expand All

(-)comms/libevdev/Makefile (-16 / +15 lines)
Lines 1-8 Link Here
1
# Created by:
2
# $FreeBSD$
1
# $FreeBSD$
3
2
4
PORTNAME=	libevdev
3
PORTNAME=	libevdev
5
PORTVERSION=	1.3.2
4
PORTVERSION=	1.4.4
6
CATEGORIES=	comms
5
CATEGORIES=	comms
7
MASTER_SITES=	http://freedesktop.org/software/${PORTNAME}/
6
MASTER_SITES=	http://freedesktop.org/software/${PORTNAME}/
8
7
Lines 9-32 MASTER_SITES= http://freedesktop.org/software/${PO Link Here
9
MAINTAINER=	hselasky@FreeBSD.org
8
MAINTAINER=	hselasky@FreeBSD.org
10
COMMENT=	Linux Event Device library
9
COMMENT=	Linux Event Device library
11
10
12
LICENSE=	GPLv2
11
LICENSE=	MIT # without linux/*.h
13
LICENSE_FILE=	${WRKSRC}/COPYING
12
LICENSE_FILE=	${WRKSRC}/COPYING
14
13
14
BUILD_DEPENDS=	v4l_compat>=1.0.20110603:${PORTSDIR}/multimedia/v4l_compat
15
16
USES=		autoreconf gmake libtool pathfix pkgconfig python:build \
17
		shebangfix tar:xz
18
EXTRACT_AFTER_ARGS=	--exclude include # v4l_compat
19
PATHFIX_MAKEFILEIN=	Makefile.am
20
SHEBANG_FILES=	libevdev/make-event-names.py
21
python_OLD_CMD=	/usr/bin/env python
15
GNU_CONFIGURE=	yes
22
GNU_CONFIGURE=	yes
23
CPPFLAGS+=	-I${LOCALBASE}/include # v4l_compat
24
INSTALL_TARGET=	install-strip
25
USE_LDCONFIG=	yes
16
26
17
USES=		autoreconf gettext gmake libtool pkgconfig python tar:xz
18
19
CONFIGURE_ARGS=	--with-pkgconfigdir="${PREFIX}/libdata/pkgconfig"
20
21
post-patch:
27
post-patch:
22
	${FIND} ${WRKSRC} -name "*.[ch]" | ${XARGS} -n 10 ${REINPLACE_CMD} \
28
	@${REINPLACE_CMD} -e '/input\.h/s,$$(top_srcdir),${LOCALBASE},' \
23
	    -e 's|linux/types.h|sys/types.h|g; \
29
		${WRKSRC}/libevdev/Makefile.am
24
		s|_IOC_READ|IOC_OUT|g; \
25
		s|_IOC_WRITE|IOC_IN|g; \
26
		s|__u8|uint8_t|g; s|__s8|int8_t|g; \
27
		s|__u16|uint16_t|g; s|__s16|int16_t|g; \
28
		s|__u32|uint32_t|g; s|__s32|int32_t|g; \
29
		s|__u64|uint64_t|g; s|__s64|int64_t|g'
30
30
31
.include <bsd.port.mk>
31
.include <bsd.port.mk>
32
(-)comms/libevdev/distinfo (-2 / +2 lines)
Lines 1-2 Link Here
1
SHA256 (libevdev-1.3.2.tar.xz) = a4317de9e818093dc131cc2bb96cdfc0cebd631e4be5c5244e1e373ce1536eed
1
SHA256 (libevdev-1.4.4.tar.xz) = ed9979369b6a6e28f5897d099538549ecffb2b7c00c1b717eb77c31d85bc45a9
2
SIZE (libevdev-1.3.2.tar.xz) = 395324
2
SIZE (libevdev-1.4.4.tar.xz) = 409856
(-)comms/libevdev/files/patch-Makefile.am (-7 / +4 lines)
Lines 1-6 Link Here
1
--- Makefile.am.orig	2013-10-22 03:34:17.000000000 +0200
1
--- Makefile.am.orig	2013-10-22 01:34:17 UTC
2
+++ Makefile.am	2015-01-12 10:13:14.000000000 +0100
2
+++ Makefile.am
3
@@ -3,9 +3,9 @@
3
@@ -3,7 +3,7 @@ PRINT_DIRECTORY_FLAGS_1=
4
 PRINT_DIRECTORY_FLAGS_0=--no-print-directory
4
 PRINT_DIRECTORY_FLAGS_0=--no-print-directory
5
 PRINT_DIRECTORY_FLAGS_=$(PRINT_DIRECTORY_FLAGS_$(AM_DEFAULT_VERBOSITY))
5
 PRINT_DIRECTORY_FLAGS_=$(PRINT_DIRECTORY_FLAGS_$(AM_DEFAULT_VERBOSITY))
6
 AM_MAKEFLAGS = $(PRINT_DIRECTORY_FLAGS_$(V))
6
 AM_MAKEFLAGS = $(PRINT_DIRECTORY_FLAGS_$(V))
Lines 7-14 Link Here
7
-SUBDIRS = doc libevdev tools test
7
-SUBDIRS = doc libevdev tools test
8
+SUBDIRS = doc libevdev
8
+SUBDIRS = doc libevdev
9
 
9
 
10
-pkgconfigdir = $(libdir)/pkgconfig
10
 pkgconfigdir = $(libdir)/pkgconfig
11
+pkgconfigdir = $(prefix)/libdata/pkgconfig
12
 pkgconfig_DATA = libevdev.pc
11
 pkgconfig_DATA = libevdev.pc
13
 
14
 EXTRA_DIST = libevdev.pc.in
(-)comms/libevdev/pkg-descr (-1 lines)
Lines 1-4 Link Here
1
This package contains the Event Device Library.
1
This package contains the Event Device Library.
2
2
3
WWW: http://www.freedesktop.org/wiki/Software/libevdev
3
WWW: http://www.freedesktop.org/wiki/Software/libevdev
4
(-)comms/libevdev/pkg-plist (-5 / +4 lines)
Lines 1-9 Link Here
1
include/libevdev-1.0/libevdev/libevdev-uinput.h
1
include/libevdev-1.0/libevdev/libevdev.h
2
include/libevdev-1.0/libevdev/libevdev.h
2
include/libevdev-1.0/libevdev/libevdev-uinput.h
3
lib/libevdev.a
3
lib/libevdev.so.2.1.5
4
lib/libevdev.so
4
lib/libevdev.so.2
5
lib/libevdev.so.2
5
lib/libevdev.so
6
lib/libevdev.so.2.1.10
6
lib/libevdev.a
7
libdata/pkgconfig/libevdev.pc
7
libdata/pkgconfig/libevdev.pc
8
man/man3/libevdev.3.gz
8
man/man3/libevdev.3.gz
9
(-)x11-drivers/xf86-input-evdev/Makefile (-16 / +8 lines)
Lines 1-29 Link Here
1
# $FreeBSD: head/x11-drivers/xf86-input-mouse/Makefile 374982 2014-12-19 23:03:54Z dumbbell $
1
# $FreeBSD: head/x11-drivers/xf86-input-mouse/Makefile 374982 2014-12-19 23:03:54Z dumbbell $
2
2
3
PORTNAME=	xf86-input-evdev
3
PORTNAME=	xf86-input-evdev
4
PORTVERSION=	2.9.1
4
PORTVERSION=	2.9.2
5
CATEGORIES=	x11-drivers
5
CATEGORIES=	x11-drivers
6
6
7
MAINTAINER=	x11@FreeBSD.org
7
MAINTAINER=	x11@FreeBSD.org
8
COMMENT=	X.Org event device input driver
8
COMMENT=	X.Org event device input driver
9
9
10
LICENSE=	MIT # various styles
11
LICENSE_FILE=	${WRKSRC}/COPYING
12
13
BUILD_DEPENDS=	v4l_compat>=1.0.20110603:${PORTSDIR}/multimedia/v4l_compat
10
LIB_DEPENDS=	libevdev.so:${PORTSDIR}/comms/libevdev
14
LIB_DEPENDS=	libevdev.so:${PORTSDIR}/comms/libevdev
11
15
12
XORG_CAT=	driver
16
XORG_CAT=	driver
17
USES=		autoreconf pathfix
18
PATHFIX_MAKEFILEIN=	Makefile.am
19
INSTALL_TARGET=	install-strip
13
20
14
GNU_CONFIGURE=yes
15
16
USES=		autoreconf gmake libtool pathfix pkgconfig gettext
17
18
post-patch:
19
	${FIND} ${WRKSRC} -name "*.[ch]" | ${XARGS} -n 10 ${REINPLACE_CMD} \
20
	    -e 's|linux/types.h|sys/types.h|g; \
21
	    	s|linux/version.h|sys/param.h|g; \
22
		s|_IOC_READ|IOC_OUT|g; \
23
		s|_IOC_WRITE|IOC_IN|g; \
24
		s|__u8|uint8_t|g; s|__s8|int8_t|g; \
25
		s|__u16|uint16_t|g; s|__s16|int16_t|g; \
26
		s|__u32|uint32_t|g; s|__s32|int32_t|g; \
27
		s|__u64|uint64_t|g; s|__s64|int64_t|g'
28
29
.include <bsd.port.mk>
21
.include <bsd.port.mk>
(-)x11-drivers/xf86-input-evdev/distinfo (-2 / +2 lines)
Lines 1-2 Link Here
1
SHA256 (xorg/driver/xf86-input-evdev-2.9.1.tar.bz2) = 0ce30328adfeac90a6f4b508d992fb834d8e50b484b29d3d58cf6683fa8502f9
1
SHA256 (xorg/driver/xf86-input-evdev-2.9.2.tar.bz2) = 792329b531afc6928ccda94e4b51a5520d4ddf8ef9a00890a5d0d31898acefec
2
SIZE (xorg/driver/xf86-input-evdev-2.9.1.tar.bz2) = 386505
2
SIZE (xorg/driver/xf86-input-evdev-2.9.2.tar.bz2) = 387095
(-)x11-drivers/xf86-input-evdev/files/patch-Makefile.am (-11 lines)
Lines 1-11 Link Here
1
--- Makefile.am.orig	2015-01-12 10:33:33.000000000 +0100
2
+++ Makefile.am	2015-01-12 10:33:44.000000000 +0100
3
@@ -25,7 +25,7 @@
4
 SUBDIRS = src man include
5
 MAINTAINERCLEANFILES = ChangeLog INSTALL
6
 
7
-pkgconfigdir = $(libdir)/pkgconfig
8
+pkgconfigdir = $(prefix)/libdata/pkgconfig
9
 pkgconfig_DATA = xorg-evdev.pc
10
 
11
 
(-)x11-drivers/xf86-input-evdev/files/patch-configure.ac (-3 / +3 lines)
Lines 1-6 Link Here
1
--- configure.ac.orig	2015-01-12 08:47:13.000000000 +0100
1
--- configure.ac.orig	2015-03-27 01:36:31 UTC
2
+++ configure.ac	2015-01-12 08:47:52.000000000 +0100
2
+++ configure.ac
3
@@ -45,7 +45,8 @@
3
@@ -45,7 +45,8 @@ XORG_DEFAULT_OPTIONS
4
 
4
 
5
 # Obtain compiler/linker options from server and required extensions
5
 # Obtain compiler/linker options from server and required extensions
6
 PKG_CHECK_MODULES(XORG, [xorg-server >= 1.10] xproto inputproto)
6
 PKG_CHECK_MODULES(XORG, [xorg-server >= 1.10] xproto inputproto)
(-)x11-drivers/xf86-input-evdev/files/patch-src-evdev.c (-62 lines)
Lines 1-62 Link Here
1
--- src/evdev.c.orig	2015-01-13 14:06:29.000000000 +0100
2
+++ src/evdev.c	2015-01-13 14:11:54.000000000 +0100
3
@@ -39,7 +39,9 @@
4
 
5
 #include <linux/version.h>
6
 #include <sys/stat.h>
7
+#ifdef __linux__
8
 #include <libudev.h>
9
+#endif
10
 #include <unistd.h>
11
 #include <errno.h>
12
 #include <fcntl.h>
13
@@ -222,6 +224,7 @@
14
 static BOOL
15
 EvdevDeviceIsVirtual(const char* devicenode)
16
 {
17
+#ifdef __linux__
18
     struct udev *udev = NULL;
19
     struct udev_device *device = NULL;
20
     struct stat st;
21
@@ -252,6 +255,9 @@
22
     udev_device_unref(device);
23
     udev_unref(udev);
24
     return rc;
25
+#else
26
+    return FALSE;
27
+#endif
28
 }
29
 
30
 #ifndef HAVE_SMOOTH_SCROLLING
31
@@ -1078,11 +1084,13 @@
32
     do {
33
         rc = libevdev_next_event(pEvdev->dev, LIBEVDEV_READ_FLAG_NORMAL, &ev);
34
         if (rc < 0) {
35
-            if (rc == -ENODEV) /* May happen after resume */
36
+            if (rc != -EAGAIN && rc != -EINTR && rc != -EWOULDBLOCK) {
37
+                /* May happen after resume or at device detach */
38
                 xf86RemoveEnabledDevice(pInfo);
39
-            else if (rc != -EAGAIN)
40
+                EvdevCloseDevice(pInfo);
41
                 LogMessageVerbSigSafe(X_ERROR, 0, "%s: Read error: %s\n", pInfo->name,
42
                                        strerror(-rc));
43
+            }
44
             break;
45
         } else if (rc == LIBEVDEV_READ_STATUS_SUCCESS) {
46
 #ifdef MULTITOUCH
47
@@ -1436,10 +1444,15 @@
48
             continue;
49
 
50
         abs = libevdev_get_abs_info(pEvdev->dev, axis);
51
+#if defined(__linux__)
52
 #if LINUX_VERSION_CODE > KERNEL_VERSION(2, 6, 30)
53
         /* Kernel provides units/mm, X wants units/m */
54
         resolution = abs->resolution * 1000;
55
 #endif
56
+#else
57
+        /* Kernel provides units/mm, X wants units/m */
58
+        resolution = abs->resolution * 1000;
59
+#endif
60
 
61
         xf86InitValuatorAxisStruct(device, axnum,
62
                                    atoms[axnum],
(-)x11-drivers/xf86-input-evdev/files/patch-src_evdev.c (-8 / +11 lines)
Lines 1-16 Link Here
1
--- src/evdev.c.orig	2015-01-13 14:06:29.000000000 +0100
1
--- src/evdev.c.orig	2015-03-27 01:35:50 UTC
2
+++ src/evdev.c	2015-01-13 14:11:54.000000000 +0100
2
+++ src/evdev.c
3
@@ -39,7 +39,9 @@
3
@@ -37,9 +37,11 @@
4
 #include <X11/keysym.h>
5
 #include <X11/extensions/XI.h>
4
 
6
 
5
 #include <linux/version.h>
7
-#include <linux/version.h>
6
 #include <sys/stat.h>
8
 #include <sys/stat.h>
7
+#ifdef __linux__
9
+#ifdef __linux__
10
+#include <linux/version.h>
8
 #include <libudev.h>
11
 #include <libudev.h>
9
+#endif
12
+#endif
10
 #include <unistd.h>
13
 #include <unistd.h>
11
 #include <errno.h>
14
 #include <errno.h>
12
 #include <fcntl.h>
15
 #include <fcntl.h>
13
@@ -222,6 +224,7 @@
16
@@ -222,6 +224,7 @@ EvdevIsDuplicate(InputInfoPtr pInfo)
14
 static BOOL
17
 static BOOL
15
 EvdevDeviceIsVirtual(const char* devicenode)
18
 EvdevDeviceIsVirtual(const char* devicenode)
16
 {
19
 {
Lines 18-24 Link Here
18
     struct udev *udev = NULL;
21
     struct udev *udev = NULL;
19
     struct udev_device *device = NULL;
22
     struct udev_device *device = NULL;
20
     struct stat st;
23
     struct stat st;
21
@@ -252,6 +255,9 @@
24
@@ -252,6 +255,9 @@ out:
22
     udev_device_unref(device);
25
     udev_device_unref(device);
23
     udev_unref(udev);
26
     udev_unref(udev);
24
     return rc;
27
     return rc;
Lines 28-34 Link Here
28
 }
31
 }
29
 
32
 
30
 #ifndef HAVE_SMOOTH_SCROLLING
33
 #ifndef HAVE_SMOOTH_SCROLLING
31
@@ -1078,11 +1084,13 @@
34
@@ -1086,11 +1092,13 @@ EvdevReadInput(InputInfoPtr pInfo)
32
     do {
35
     do {
33
         rc = libevdev_next_event(pEvdev->dev, LIBEVDEV_READ_FLAG_NORMAL, &ev);
36
         rc = libevdev_next_event(pEvdev->dev, LIBEVDEV_READ_FLAG_NORMAL, &ev);
34
         if (rc < 0) {
37
         if (rc < 0) {
Lines 44-50 Link Here
44
             break;
47
             break;
45
         } else if (rc == LIBEVDEV_READ_STATUS_SUCCESS) {
48
         } else if (rc == LIBEVDEV_READ_STATUS_SUCCESS) {
46
 #ifdef MULTITOUCH
49
 #ifdef MULTITOUCH
47
@@ -1436,10 +1444,15 @@
50
@@ -1470,10 +1478,15 @@ EvdevAddAbsValuatorClass(DeviceIntPtr de
48
             continue;
51
             continue;
49
 
52
 
50
         abs = libevdev_get_abs_info(pEvdev->dev, axis);
53
         abs = libevdev_get_abs_info(pEvdev->dev, axis);
(-)x11-drivers/xf86-input-evdev/files/patch-src_evdev.h (+19 lines)
Line 0 Link Here
1
--- src/evdev.h.orig	2015-03-27 01:35:50 UTC
2
+++ src/evdev.h
3
@@ -36,7 +36,15 @@
4
 #define EVDEV_H
5
 
6
 #include <linux/input.h>
7
-#include <linux/types.h>
8
+#include <sys/types.h>
9
+
10
+/* XXX Copied from <xf86str.h> for linux */
11
+/* Tolerate prior #include <linux/input.h> */
12
+#undef BUS_NONE
13
+#undef BUS_PCI
14
+#undef BUS_SBUS
15
+#undef BUS_PLATFORM
16
+#undef BUS_last
17
 
18
 #include <xorg-server.h>
19
 #include <xf86Xinput.h>
(-)x11-drivers/xf86-input-evdev/pkg-plist (-1 lines)
Lines 2-5 include/xorg/evdev-properties.h Link Here
2
lib/xorg/modules/input/evdev_drv.so
2
lib/xorg/modules/input/evdev_drv.so
3
libdata/pkgconfig/xorg-evdev.pc
3
libdata/pkgconfig/xorg-evdev.pc
4
man/man4/evdev.4x.gz
4
man/man4/evdev.4x.gz
5

Return to bug 196978