diff options
author | jbeich <jbeich@FreeBSD.org> | 2015-09-17 12:14:08 +0800 |
---|---|---|
committer | jbeich <jbeich@FreeBSD.org> | 2015-09-17 12:14:08 +0800 |
commit | 8df49627325d8c00d2e33f8181046c6e42ff5ad3 (patch) | |
tree | 0ef2abe13adf2e2d639d37a53ef7c834a3286bf3 /devel | |
parent | 9bdc72ac148492977954a6b2542c2f61a2f6c984 (diff) | |
download | freebsd-ports-graphics-8df49627325d8c00d2e33f8181046c6e42ff5ad3.tar.gz freebsd-ports-graphics-8df49627325d8c00d2e33f8181046c6e42ff5ad3.tar.zst freebsd-ports-graphics-8df49627325d8c00d2e33f8181046c6e42ff5ad3.zip |
devel/py-evdev: add new port
This package provides bindings to the generic input event interface in
Linux. The evdev interface serves the purpose of passing events
generated in the kernel directly to userspace through character
devices that are typically located in /dev/input/.
This package also comes with bindings to uinput, the userspace input
subsystem. Uinput allows userspace programs to create and handle input
devices that can inject events directly into the input subsystem.
https://pypi.python.org/pypi/evdev
Diffstat (limited to 'devel')
-rw-r--r-- | devel/Makefile | 1 | ||||
-rw-r--r-- | devel/py-evdev/Makefile | 29 | ||||
-rw-r--r-- | devel/py-evdev/distinfo | 2 | ||||
-rw-r--r-- | devel/py-evdev/files/patch-v4l_compat | 46 | ||||
-rw-r--r-- | devel/py-evdev/pkg-descr | 10 |
5 files changed, 88 insertions, 0 deletions
diff --git a/devel/Makefile b/devel/Makefile index d418277bd8e..207f26eb485 100644 --- a/devel/Makefile +++ b/devel/Makefile @@ -3961,6 +3961,7 @@ SUBDIR += py-eggtestinfo SUBDIR += py-enum34 SUBDIR += py-epsilon + SUBDIR += py-evdev SUBDIR += py-event SUBDIR += py-experimental.cssselect SUBDIR += py-extras diff --git a/devel/py-evdev/Makefile b/devel/py-evdev/Makefile new file mode 100644 index 00000000000..e93bc54de2c --- /dev/null +++ b/devel/py-evdev/Makefile @@ -0,0 +1,29 @@ +# $FreeBSD$ + +PORTNAME= evdev +PORTVERSION= 0.5.0 +CATEGORIES= devel python +MASTER_SITES= CHEESESHOP +PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX} + +MAINTAINER= hselasky@FreeBSD.org +COMMENT= Bindings to the Linux input handling subsystem + +LICENSE= BSD3CLAUSE +LICENSE_FILE= ${WRKSRC}/LICENSE + +BUILD_DEPENDS= v4l_compat>=1.0.20110603:${PORTSDIR}/multimedia/v4l_compat + +USES= python +USE_PYTHON= autoplist distutils +CPPFLAGS+= -I${LOCALBASE}/include # v4l_compat + +post-patch: + @${REINPLACE_CMD} -e '/header/s,/usr,${LOCALBASE},' \ + ${WRKSRC}/${PYSETUP} + +post-install: + ${FIND} ${STAGEDIR}${PYTHONPREFIX_SITELIBDIR} \ + -name '*.so' -exec ${STRIP_CMD} {} + + +.include <bsd.port.mk> diff --git a/devel/py-evdev/distinfo b/devel/py-evdev/distinfo new file mode 100644 index 00000000000..399a3b2dac4 --- /dev/null +++ b/devel/py-evdev/distinfo @@ -0,0 +1,2 @@ +SHA256 (evdev-0.5.0.tar.gz) = 509f0f6ce5a12315fcad0b7f9b41cbdfc5c5f49a7cecdd6a88ce5c1d04f6827c +SIZE (evdev-0.5.0.tar.gz) = 23931 diff --git a/devel/py-evdev/files/patch-v4l_compat b/devel/py-evdev/files/patch-v4l_compat new file mode 100644 index 00000000000..49edbad18ea --- /dev/null +++ b/devel/py-evdev/files/patch-v4l_compat @@ -0,0 +1,46 @@ +# XXX Patch churn from GSoC 2014, expect v4l_compat for now + +--- evdev/genecodes.py~ 2014-10-07 20:16:56 UTC ++++ evdev/genecodes.py +@@ -11,11 +11,7 @@ import os, sys, re + + template = r''' + #include <Python.h> +-#ifdef __FreeBSD__ +-#include <dev/evdev/input.h> +-#else + #include <linux/input.h> +-#endif + + /* Automatically generated by evdev.genecodes */ + /* Generated on %s */ +--- evdev/input.c.orig 2014-10-07 20:16:59 UTC ++++ evdev/input.c +@@ -18,11 +18,7 @@ + #include <fcntl.h> + #include <unistd.h> + +-#ifdef __FreeBSD__ +-#include <dev/evdev/input.h> +-#else + #include <linux/input.h> +-#endif + + #define MAX_NAME_SIZE 256 + +--- evdev/uinput.c.orig 2014-10-07 20:17:06 UTC ++++ evdev/uinput.c +@@ -8,13 +8,8 @@ + #include <fcntl.h> + #include <unistd.h> + +-#ifdef __FreeBSD__ +-#include <dev/evdev/input.h> +-#include <dev/evdev/uinput.h> +-#else + #include <linux/input.h> + #include <linux/uinput.h> +-#endif + + int _uinput_close(int fd) + { diff --git a/devel/py-evdev/pkg-descr b/devel/py-evdev/pkg-descr new file mode 100644 index 00000000000..deb1fbe469c --- /dev/null +++ b/devel/py-evdev/pkg-descr @@ -0,0 +1,10 @@ +This package provides bindings to the generic input event interface in +Linux. The evdev interface serves the purpose of passing events +generated in the kernel directly to userspace through character +devices that are typically located in /dev/input/. + +This package also comes with bindings to uinput, the userspace input +subsystem. Uinput allows userspace programs to create and handle input +devices that can inject events directly into the input subsystem. + +WWW: https://pypi.python.org/pypi/evdev |