mirror of
https://github.com/LibreELEC/LibreELEC.tv.git
synced 2025-08-01 15:07:49 +00:00
new package: add package 'eventlirc'
Signed-off-by: Stephan Raue <stephan@openelec.tv>
This commit is contained in:
parent
45d7c4171e
commit
815df2a36e
17
packages/sysutils/remote/eventlircd/build
Executable file
17
packages/sysutils/remote/eventlircd/build
Executable file
@ -0,0 +1,17 @@
|
||||
#!/bin/sh
|
||||
|
||||
. config/options $1
|
||||
|
||||
cd $PKG_BUILD
|
||||
|
||||
$AUTORECONF
|
||||
|
||||
./configure --host=$TARGET_NAME \
|
||||
--build=$HOST_NAME \
|
||||
--prefix=/usr \
|
||||
--sbindir=/usr/sbin \
|
||||
--exec-prefix=/usr \
|
||||
--localstatedir=/var \
|
||||
--sysconfdir=/etc \
|
||||
|
||||
make
|
30
packages/sysutils/remote/eventlircd/init.d/33_eventlircd
Executable file
30
packages/sysutils/remote/eventlircd/init.d/33_eventlircd
Executable file
@ -0,0 +1,30 @@
|
||||
#!/bin/sh
|
||||
|
||||
################################################################################
|
||||
# Copyright (C) 2009-2010 OpenELEC.tv
|
||||
# http://www.openelec.tv
|
||||
#
|
||||
# This Program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation; either version 2, or (at your option)
|
||||
# any later version.
|
||||
#
|
||||
# This Program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with OpenELEC.tv; see the file COPYING. If not, write to
|
||||
# the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
# http://www.gnu.org/copyleft/gpl.html
|
||||
################################################################################
|
||||
|
||||
# start the LIRC daemon
|
||||
#
|
||||
# runlevels: openelec, textmode
|
||||
|
||||
. /etc/profile
|
||||
|
||||
mkdir -p /var/run/lirc
|
||||
eventlircd --evmap=/etc/eventlircd.d --socket=/var/run/lirc/lircd --release=_UP
|
19
packages/sysutils/remote/eventlircd/install
Executable file
19
packages/sysutils/remote/eventlircd/install
Executable file
@ -0,0 +1,19 @@
|
||||
#!/bin/sh
|
||||
|
||||
. config/options $1
|
||||
|
||||
mkdir -p $INSTALL/usr/sbin
|
||||
cp $PKG_BUILD/src/eventlircd $INSTALL/usr/sbin
|
||||
|
||||
mkdir -p $INSTALL/etc/eventlircd.d
|
||||
cp $PKG_BUILD/etc/*.evmap $INSTALL/etc/eventlircd.d
|
||||
|
||||
mkdir -p $INSTALL/lib/udev
|
||||
cp $PKG_BUILD/udev/lircd_helper $INSTALL/lib/udev
|
||||
chmod +x $INSTALL/lib/udev/lircd_helper
|
||||
cp $PKG_BUILD/udev/wakeup_enable $INSTALL/lib/udev
|
||||
chmod +x $INSTALL/lib/udev/wakeup_enable
|
||||
|
||||
mkdir -p $INSTALL/lib/udev/rules.d
|
||||
cp $PKG_BUILD/udev/rules.d/98-eventlircd.rules.disabled $INSTALL/lib/udev/rules.d/98-eventlircd.rules
|
||||
cp $PKG_BUILD/udev/rules.d/98-lircd.rules.disabled $INSTALL/lib/udev/rules.d/98-lircd.rules
|
14
packages/sysutils/remote/eventlircd/meta
Normal file
14
packages/sysutils/remote/eventlircd/meta
Normal file
@ -0,0 +1,14 @@
|
||||
PKG_NAME="eventlircd"
|
||||
PKG_VERSION="17"
|
||||
PKG_REV="1"
|
||||
PKG_ARCH="any"
|
||||
PKG_LICENSE="GPL"
|
||||
PKG_SITE="http://code.google.com/p/eventlircd"
|
||||
PKG_URL="http://sources.openelec.tv/svn/$PKG_NAME-$PKG_VERSION.tar.bz2"
|
||||
PKG_DEPENDS="udev"
|
||||
PKG_BUILD_DEPENDS="toolchain udev"
|
||||
PKG_PRIORITY="optional"
|
||||
PKG_SECTION="system/remote"
|
||||
PKG_SHORTDESC="eventlircd:The eventlircd daemon provides various functions for LIRC devices"
|
||||
PKG_LONGDESC="The eventlircd daemon provides four functions for LIRC devices"
|
||||
PKG_IS_ADDON="no"
|
@ -0,0 +1,78 @@
|
||||
diff -Naur eventlircd-17/etc/ircore.evmap eventlircd-17.patch/etc/ircore.evmap
|
||||
--- eventlircd-17/etc/ircore.evmap 1970-01-01 01:00:00.000000000 +0100
|
||||
+++ eventlircd-17.patch/etc/ircore.evmap 2010-09-18 19:43:56.000000000 +0200
|
||||
@@ -0,0 +1,22 @@
|
||||
+KEY_1 = KEY_NUMERIC_1
|
||||
+KEY_2 = KEY_NUMERIC_2
|
||||
+KEY_3 = KEY_NUMERIC_3
|
||||
+KEY_4 = KEY_NUMERIC_4
|
||||
+KEY_5 = KEY_NUMERIC_5
|
||||
+KEY_6 = KEY_NUMERIC_6
|
||||
+KEY_7 = KEY_NUMERIC_7
|
||||
+KEY_8 = KEY_NUMERIC_8
|
||||
+KEY_9 = KEY_NUMERIC_9
|
||||
+KEY_0 = KEY_NUMERIC_0
|
||||
+KEY_E = KEY_BACK
|
||||
+KEY_KP1 = KEY_NUMERIC_1
|
||||
+KEY_KP2 = KEY_NUMERIC_2
|
||||
+KEY_KP3 = KEY_NUMERIC_3
|
||||
+KEY_KP4 = KEY_NUMERIC_4
|
||||
+KEY_KP5 = KEY_NUMERIC_5
|
||||
+KEY_KP6 = KEY_NUMERIC_6
|
||||
+KEY_KP7 = KEY_NUMERIC_7
|
||||
+KEY_KP8 = KEY_NUMERIC_8
|
||||
+KEY_KP9 = KEY_NUMERIC_9
|
||||
+KEY_KP0 = KEY_NUMERIC_0
|
||||
+KEY_KPASTERISK = KEY_NUMERIC_STAR
|
||||
diff -Naur eventlircd-17/udev/lircd_helper.in eventlircd-17.patch/udev/lircd_helper.in
|
||||
--- eventlircd-17/udev/lircd_helper.in 2010-09-18 19:43:56.000000000 +0200
|
||||
+++ eventlircd-17.patch/udev/lircd_helper.in 2010-09-27 19:46:24.948885231 +0200
|
||||
@@ -53,7 +53,7 @@
|
||||
remove)
|
||||
instance=`echo $DEVNAME | sed -e 's/\/\+/~/g' -e 's/^~dev~//'`
|
||||
if test -e "@localstatedir@/run/lirc/lircd-${instance}.pid" ; then
|
||||
- pid=`cat @localstate@/run/lirc/lircd-${instance}.pid`
|
||||
+ pid=`cat @localstatedir@/run/lirc/lircd-${instance}.pid`
|
||||
if test ! "x${pid}" = "x" ; then
|
||||
kill ${pid}
|
||||
fi
|
||||
diff -Naur eventlircd-17/udev/rules.d/98-eventlircd.rules.disabled.in eventlircd-17.patch/udev/rules.d/98-eventlircd.rules.disabled.in
|
||||
--- eventlircd-17/udev/rules.d/98-eventlircd.rules.disabled.in 2010-09-18 19:43:56.000000000 +0200
|
||||
+++ eventlircd-17.patch/udev/rules.d/98-eventlircd.rules.disabled.in 2010-09-27 21:21:25.123009701 +0200
|
||||
@@ -51,6 +51,13 @@
|
||||
ENV{eventlircd_enable}="true"
|
||||
|
||||
#-------------------------------------------------------------------------------
|
||||
+# Ask eventlircd to handle input event devices created by ir-core (kernel).
|
||||
+#-------------------------------------------------------------------------------
|
||||
+SUBSYSTEMS=="rc", \
|
||||
+ ENV{eventlircd_enable}="true"
|
||||
+ ENV{eventlircd_evmap}="ircore.evmap"
|
||||
+
|
||||
+#-------------------------------------------------------------------------------
|
||||
# Ask eventlircd to handle USB HID devices that show up as event devices and are
|
||||
# known to be remote controls. For simplicity, the event map file names have the
|
||||
# format <BUSTYPE>_<VENDOR>_<PRODUCT>.evmap.
|
||||
diff -Naur eventlircd-17/udev/wakeup_enable.in eventlircd-17.patch/udev/wakeup_enable.in
|
||||
--- eventlircd-17/udev/wakeup_enable.in 2010-09-18 19:43:56.000000000 +0200
|
||||
+++ eventlircd-17.patch/udev/wakeup_enable.in 2010-09-27 19:53:32.215884397 +0200
|
||||
@@ -5,13 +5,13 @@
|
||||
|
||||
devpath=`readlink -f "/sys/${DEVPATH}"`
|
||||
while echo "${devpath}" | /bin/grep -q '^/sys/devices/' > /dev/null 2>&1 ; do
|
||||
- if test -e "${devpath}/power/wakeup" ; then
|
||||
- state=`cat "${devpath}/power/wakeup"`
|
||||
+ if test -e "${devpath}/power/wakeup" ; then
|
||||
+ state=`cat "${devpath}/power/wakeup"`
|
||||
if test "x${state}" = "xdisabled" ; then
|
||||
echo "enabled" > "${devpath}/power/wakeup"
|
||||
- fi
|
||||
- fi
|
||||
+ fi
|
||||
+ fi
|
||||
devpath=`dirname "${devpath}"`
|
||||
-done
|
||||
-
|
||||
+done
|
||||
+
|
||||
exit 0
|
Loading…
x
Reference in New Issue
Block a user