lirc-tools: new package
PATCH v5 1/1 lirc-tools: new package
This package adds the userspace tools and daemons LIRC - Linux remote control
--- package/lirc-tools/Config.in | 17 +++++++++++++++++ package/lirc-tools/S25lircd | 38 ++++++++++++++++++++++++++++++++++++++ package/lirc-tools/lirc-tools.hash | 2 ++ package/lirc-tools/lirc-tools.mk | 19 +++++++++++++++++++ 4 files changed, 76 insertions(+) create mode 100644 package/lirc-tools/Config.in create mode 100755 package/lirc-tools/S25lircd create mode 100644 package/lirc-tools/lirc-tools.hash create mode 100644 package/lirc-tools/lirc-tools.mk
package/lirc-tools/Config.in new file +17 -0
@@ -0,0 +1,17 @@ +config BR2_PACKAGE_LIRC_TOOLS + bool "lirc-tools" + help + Linux Infrared Remote Control IR receiver/transmitter Daemon and tools + LIRC is a package that supports receiving and sending IR + signals of the most common IR remote controls. It contains a + daemon that decodes and sends IR signals, a mouse daemon + that translates IR signals to mouse movements and a couple + of user programs that allow to control your computer with a + remote control. + + lircd, irw, irrecord, mode2 etc + + Requires the kernel LIRC interface driver , add modules to support + your hardware. + + http://www.lirc.org/
package/lirc-tools/S25lircd new file +38 -0
@@ -0,0 +1,38 @@ +#!/bin/sh +# +# Start lirc +# +# Support for remotes - Add remotes to /etc/lirc/lircd.conf.d/ +# + +start() { + echo -n "Starting lirc: " + mkdir /var/run/lirc + ln -s /var/run/lirc/lircd /dev/lircd + start-stop-daemon -b -S -q -m -p /var/run/lirc.pid --exec /usr/sbin/lircd -- -O /etc/lirc/lirc_options.conf + echo "OK" +} + +stop() { + echo -n "Stopping lirc: " + start-stop-daemon -K -q -p /var/run/lirc.pid + echo "OK" +} + +case "$1" in + start) + start + ;; + stop) + stop + ;; + restart|reload) + stop + start + ;; + *) + echo "Usage: $0 {start|stop|restart}" + exit 1 +esac + +exit $?
package/lirc-tools/lirc-tools.hash new file +2 -0
@@ -0,0 +1,2 @@ +#hash from http://sourceforge.net/projects/lirc/files/LIRC/0.9.2/ +sha1 585daed1eaa169b9683a507e26b1331a947a4dcd lirc-0.9.2.tar.bz2
package/lirc-tools/lirc-tools.mk new file +19 -0
@@ -0,0 +1,19 @@ +################################################################################ +# +# lirc-tools +# +################################################################################ + +LIRC_TOOLS_VERSION = 0.9.2 +LIRC_TOOLS_SOURCE = lirc-$(LIRC_TOOLS_VERSION).tar.bz2 +LIRC_TOOLS_SITE = http://downloads.sourceforge.net/project/lirc/LIRC/$(LIRC_TOOLS_VERSION)/ +LIRC_TOOLS_LICENSE = GPLv2+ +LIRC_TOOLS_LICENSE_FILES = COPYING + +LIRC_TOOLS_CONF_OPTS = --without-x --enable-sandboxed --with-driver=userspace + +define LIRC_TOOLS_INSTALL_INIT_SYSV + $(INSTALL) -D -m 0755 package/lirc-tools/S25lircd $(TARGET_DIR)/etc/init.d/ +endef + +$(eval $(autotools-package))
Signature · 1 line
2.3.2
PATCH v5 1/1 lirc-tools: new package
Hi Rhys,
Quoted 4 lines · Rhys Williams
This package adds the userspace tools and daemons LIRC - Linux remote control
Signed-off-by Rhys Williams <[email protected]>
baruch
Signature · 3 lines
http://baruch.siach.name/blog/ ~. .~ Tk Open Systems
=}------------------------------------------------ooO--U--Ooo------------{=
- baruch at tkos.co.il - tel: +972.2.679.5364, http://www.tkos.co.il -PATCH v5 1/1 lirc-tools: new package
In reply to Rhys WilliamsDear Rhys Williams,
Cc'ing Baruch since he gave his Reviewed-by on this patch.
Quoted 4 lines · Rhys Williams
This package adds the userspace tools and daemons LIRC - Linux remote control
Signed-off-by Rhys Williams <[email protected]>
Thanks, I've applied your patch after doing a number of fixes/improvements to it. See below.
package/lirc-tools/Config.in line 2
Quoted 8 lines
package/lirc-tools/Config.in new file +2
-0@@ -0,0 +1,17 @@ +config BR2_PACKAGE_LIRC_TOOLS + bool "lirc-tools"
Missing dependency on BR2_USE_MMU, since fork() is used in lirc-tools.
package/lirc-tools/Config.in line 10
Quoted 8 lines
package/lirc-tools/Config.in new file +8
-0+ help + Linux Infrared Remote Control IR receiver/transmitter Daemon and tools + LIRC is a package that supports receiving and sending IR + signals of the most common IR remote controls. It contains a + daemon that decodes and sends IR signals, a mouse daemon + that translates IR signals to mouse movements and a couple + of user programs that allow to control your computer with a + remote control.
Lines too long, the text should be wrapped to a smaller length.
package/lirc-tools/Config.in line 12
Quoted 1 line
package/lirc-tools/Config.in new file +1
-0+ lircd, irw, irrecord, mode2 etc
This doesn't make much sense if there is no indication about what this means, so I've removed this part.
package/lirc-tools/Config.in line 15
Quoted 2 lines
package/lirc-tools/Config.in new file +2
-0+ Requires the kernel LIRC interface driver , add modules to support + your hardware.
I've slightly reworded since, and removed the space before comma.
Quoted 8 lines
package/lirc-tools/Config.in new file +2
-0+ + http://www.lirc.org/package/lirc-tools/S25lircd new file +0
-0
package/lirc-tools/S25lircd line 10
Quoted 10 lines
package/lirc-tools/S25lircd new file +10
-0@@ -0,0 +1,38 @@ +#!/bin/sh +# +# Start lirc +# +# Support for remotes - Add remotes to /etc/lirc/lircd.conf.d/ +# + +start() { + echo -n "Starting lirc: " + mkdir /var/run/lirc
This means that re-execution of the start step is not possible. I've changed that to 'mkdir -p'.
package/lirc-tools/S25lircd line 11
Quoted 1 line
package/lirc-tools/S25lircd new file +1
-0+ ln -s /var/run/lirc/lircd /dev/lircd
Same issue, I've changed to 'ln -sf'.
package/lirc-tools/S25lircd line 12
Quoted 1 line
package/lirc-tools/S25lircd new file +1
-0+ start-stop-daemon -b -S -q -m -p /var/run/lirc.pid --exec /usr/sbin/lircd -- -O /etc/lirc/lirc_options.conf
With this, lircd continues to daemonize itself, so the pid stored in /var/run/lirc.pid is not the real PID of the lircd daemon. I've changed this to pass the '-n' option to lircd so that it doesn't daemonize itself.
Quoted 12 lines
package/lirc-tools/lirc-tools.mk new file +6
-0@@ -0,0 +1,19 @@ +################################################################################ +# +# lirc-tools +# +################################################################################ +
package/lirc-tools/lirc-tools.mk line 16
Quoted 10 lines
package/lirc-tools/lirc-tools.mk new file +10
-0+LIRC_TOOLS_VERSION = 0.9.2 +LIRC_TOOLS_SOURCE = lirc-$(LIRC_TOOLS_VERSION).tar.bz2 +LIRC_TOOLS_SITE = http://downloads.sourceforge.net/project/lirc/LIRC/$(LIRC_TOOLS_VERSION)/ +LIRC_TOOLS_LICENSE = GPLv2+ +LIRC_TOOLS_LICENSE_FILES = COPYING + +LIRC_TOOLS_CONF_OPTS = --without-x --enable-sandboxed --with-driver=userspace + +define LIRC_TOOLS_INSTALL_INIT_SYSV + $(INSTALL) -D -m 0755 package/lirc-tools/S25lircd $(TARGET_DIR)/etc/init.d/
A full destination path is what we use when calling $(INSTALL), so I've changed this as well.
But the most problematic issue was actually that your new package Config.in file was not included anywhere! Seems like you forgot to 'git add package/Config.in'.
Committed with those issues fixed, see
http://git.buildroot.net/buildroot/commit/?id=1ba7e76d5786114e05482ae6528e6da61eb12be3
for more details.
Thanks,
Thomas
Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons Embedded Linux, Kernel and Android engineering http://free-electrons.com