From 1f9979e09ed41bb2f02c1b735f44a99d15f0131a Mon Sep 17 00:00:00 2001 From: Mateusz Piotrowski <0mp@FreeBSD.org> Date: Sat, 10 Oct 2020 11:53:46 +0000 Subject: Add x11/inputplug inputplug is a very simple daemon which monitors XInput events and runs arbitrary scripts on hierarchy change events (such as a device being attached, removed, enabled or disabled). For example, inputplug can be used in shell scripts which monitor attachments of keyboards in order to run change keyboard mappings with commands like "setxkbmap -option ctrl:nocaps". WWW: https://github.com/andrewshadura/inputplug --- x11/inputplug/Makefile | 26 ++++++++++++++++++++++++++ x11/inputplug/distinfo | 3 +++ x11/inputplug/files/patch-inputplug.c | 12 ++++++++++++ x11/inputplug/pkg-descr | 9 +++++++++ 4 files changed, 50 insertions(+) create mode 100644 x11/inputplug/Makefile create mode 100644 x11/inputplug/distinfo create mode 100644 x11/inputplug/files/patch-inputplug.c create mode 100644 x11/inputplug/pkg-descr (limited to 'x11/inputplug') diff --git a/x11/inputplug/Makefile b/x11/inputplug/Makefile new file mode 100644 index 000000000000..e8791764ab9e --- /dev/null +++ b/x11/inputplug/Makefile @@ -0,0 +1,26 @@ +# $FreeBSD$ + +PORTNAME= inputplug +DISTVERSION= 0.3 +CATEGORIES= x11 + +MAINTAINER= 0mp@FreeBSD.org +COMMENT= XInput event monitor daemon + +LICENSE= MIT +LICENSE_FILE= ${WRKSRC}/LICENSE + +BUILD_DEPENDS= mk-configure>=0:devel/mk-configure + +USES= localbase perl5 pkgconfig xorg +USE_GITHUB= yes +GH_ACCOUNT= andrewshadura +USE_PERL5= build +USE_XORG= x11 xcb xi +MAKE_CMD= mkcmake +MAKE_ARGS= MANDIR="${PREFIX}/share/man" + +PLIST_FILES= bin/inputplug \ + share/man/man1/inputplug.1.gz + +.include diff --git a/x11/inputplug/distinfo b/x11/inputplug/distinfo new file mode 100644 index 000000000000..ca4c1bd2ba95 --- /dev/null +++ b/x11/inputplug/distinfo @@ -0,0 +1,3 @@ +TIMESTAMP = 1602328140 +SHA256 (andrewshadura-inputplug-0.3_GH0.tar.gz) = acac8e3972f3f10f9b6791321d2441e6b54d93d97c2de81e13eb14734a635ef7 +SIZE (andrewshadura-inputplug-0.3_GH0.tar.gz) = 7003 diff --git a/x11/inputplug/files/patch-inputplug.c b/x11/inputplug/files/patch-inputplug.c new file mode 100644 index 000000000000..ff925db96e55 --- /dev/null +++ b/x11/inputplug/files/patch-inputplug.c @@ -0,0 +1,12 @@ +--- inputplug.c.orig 2020-10-10 11:36:14 UTC ++++ inputplug.c +@@ -3,6 +3,9 @@ + #include + #include + #include ++#if __FreeBSD__ ++#include ++#endif + #include + #include + #include diff --git a/x11/inputplug/pkg-descr b/x11/inputplug/pkg-descr new file mode 100644 index 000000000000..d210519b4b86 --- /dev/null +++ b/x11/inputplug/pkg-descr @@ -0,0 +1,9 @@ +inputplug is a very simple daemon which monitors XInput events and runs +arbitrary scripts on hierarchy change events (such as a device being attached, +removed, enabled or disabled). + +For example, inputplug can be used in shell scripts which monitor attachments +of keyboards in order to run change keyboard mappings with commands like +"setxkbmap -option ctrl:nocaps". + +WWW: https://github.com/andrewshadura/inputplug -- cgit v1.2.3