EAPI=5 inherit user DESCRIPTION="Listens to key press/release events from a keyboard or a mouse and allows sending fake key events to an X display." HOMEPAGE="http://efre.nl/crolix/${PN}/" SRC_URI="http://efre.nl/crolix/${PN}/downloads/${P}.tar.xz" LICENSE="GPL-3" SLOT="0" KEYWORDS="x86 amd64" IUSE="" DEPEND="x11-libs/libX11 x11-libs/libXtst" RDEPEND="${DEPEND}" src_configure() { econf --without-input-group || die "econf failed" } src_compile() { emake || die "emake failed" } src_install() { emake DESTDIR="${D}" install || die "emake install failed" } pkg_preinst() { enewgroup input fowners :input /usr/bin/key-scripter || die "fowners :input key-scripter failed" fperms g+s /usr/bin/key-scripter || die "fperms g+s key-scripter failed" dodir /etc/local.d exeinto /etc/local.d echo -e "#!/bin/sh\nchown :input /dev/input/event* && chmod g+r /dev/input/event*" | newexe - key-scripter.start } pkg_postinst() { elog "Note: remember to add local to the default runlevel if that has not been done already:" elog "" elog "rc-update add local default" elog "" }