diff --git a/lirc/.footprint b/lirc/.footprint new file mode 100644 index 000000000..0c645e4ac --- /dev/null +++ b/lirc/.footprint @@ -0,0 +1,40 @@ +drwxr-xr-x root/root etc/ +drwxr-xr-x root/root etc/rc.d/ +-rwxr-xr-x root/root etc/rc.d/lircd +drwxr-xr-x root/root usr/ +drwxr-xr-x root/root usr/bin/ +-rwxr-xr-x root/root usr/bin/ircat +-rwxr-xr-x root/root usr/bin/irexec +-rwxr-xr-x root/root usr/bin/irpty +-rwxr-xr-x root/root usr/bin/irrecord +-rwxr-xr-x root/root usr/bin/irsend +-rwxr-xr-x root/root usr/bin/irw +-rwxr-xr-x root/root usr/bin/lircrcd +-rwxr-xr-x root/root usr/bin/mode2 +drwxr-xr-x root/root usr/include/ +drwxr-xr-x root/root usr/include/lirc/ +-rw-r--r-- root/root usr/include/lirc/lirc_client.h +drwxr-xr-x root/root usr/lib/ +-rwxr-xr-x root/root usr/lib/liblirc_client.la +lrwxrwxrwx root/root usr/lib/liblirc_client.so -> liblirc_client.so.0.2.0 +lrwxrwxrwx root/root usr/lib/liblirc_client.so.0 -> liblirc_client.so.0.2.0 +-rwxr-xr-x root/root usr/lib/liblirc_client.so.0.2.0 +drwxr-xr-x root/root usr/man/ +drwxr-xr-x root/root usr/man/man1/ +-rw-r--r-- root/root usr/man/man1/ircat.1.gz +-rw-r--r-- root/root usr/man/man1/irexec.1.gz +-rw-r--r-- root/root usr/man/man1/irpty.1.gz +-rw-r--r-- root/root usr/man/man1/irrecord.1.gz +-rw-r--r-- root/root usr/man/man1/irsend.1.gz +-rw-r--r-- root/root usr/man/man1/irw.1.gz +-rw-r--r-- root/root usr/man/man1/irxevent.1.gz +-rw-r--r-- root/root usr/man/man1/lircrcd.1.gz +-rw-r--r-- root/root usr/man/man1/mode2.1.gz +-rw-r--r-- root/root usr/man/man1/smode2.1.gz +-rw-r--r-- root/root usr/man/man1/xmode2.1.gz +drwxr-xr-x root/root usr/man/man8/ +-rw-r--r-- root/root usr/man/man8/lircd.8.gz +-rw-r--r-- root/root usr/man/man8/lircmd.8.gz +drwxr-xr-x root/root usr/sbin/ +-rwxr-xr-x root/root usr/sbin/lircd +-rwxr-xr-x root/root usr/sbin/lircmd diff --git a/lirc/.md5sum b/lirc/.md5sum new file mode 100644 index 000000000..ff5b278c3 --- /dev/null +++ b/lirc/.md5sum @@ -0,0 +1,3 @@ +40f056cd6de6df25be459a37f3291d4c irxevent_name.diff +83e7060a6693b81075c178d7e3b215af lirc-0.8.2.tar.bz2 +22eb1f55aaf27e0417d1e53c891fe01e lircd diff --git a/lirc/Pkgfile b/lirc/Pkgfile new file mode 100644 index 000000000..e726417fd --- /dev/null +++ b/lirc/Pkgfile @@ -0,0 +1,46 @@ +# Description: Linux Infrared Remote Control +# URL: http://www.lirc.org/ +# Maintainer: Alan Mizrahi, alan at mizrahi dot com dot ve +# +# Depends on: + +name=lirc +version=0.8.2 +release=1 +source=(http://dl.sourceforge.net/$name/$name-$version.tar.bz2 irxevent_name.diff lircd) + +# Possible drivers: +# +# none, any, act200l, animax, atiusb, audio, avermedia, avermedia_vdomate, +# avermedia98, bestbuy, bestbuy2, breakoutbox, bte, caraca, chronos, comX, +# creative_infracd, dsp, cph03x, cph06x, creative, devinput, flyvideo, +# gvbctv5pci, hauppauge, hauppauge_dvb, hercules_smarttv_stereo, irdeo, +# irdeo_remote, irman, irreal, it87, knc_one, kworld, leadtek_0007, +# leadtek_0010, livedrive_midi, livedrive_seq, logitech, lptX, mceusb, +# mediafocusI, mp3anywhere, packard_bell, parallel, pctv, pixelview_bt878, +# pixelview_pak, pixelview_pro, provideo, realmagic, remotemaster, sa1100, +# sasem, serial, silitek, sir, slinke, tekram, tekram_bt829, tira, tvbox, +# udp, uirt2, uirt2_raw + +# To select the driver, you can uncomment this: +# LIRC_DRIVER=userspace +# or you can set it up as an environment variable before running pkgmk +# or you will be asked interactively + +build() { + cd lirc-$version + + # Patch to let irxevent use different program names + patch -p1 -i $SRC/irxevent_name.diff + + if [ -z "$LIRC_DRIVER" ]; then + ./setup.sh + ./configure.sh --prefix=/usr --disable-static + else + ./configure --prefix=/usr --disable-static --with-driver="$LIRC_DRIVER" + fi + make + make DESTDIR=$PKG install + install -D -m 755 $SRC/lircd $PKG/etc/rc.d/lircd + rm -rf $PKG/dev +} diff --git a/lirc/irxevent_name.diff b/lirc/irxevent_name.diff new file mode 100644 index 000000000..2bb0b113c --- /dev/null +++ b/lirc/irxevent_name.diff @@ -0,0 +1,51 @@ +--- lirc-0.8.2/tools/irxevent.c.orig 2008-04-17 11:10:26.113550983 -0430 ++++ lirc-0.8.2/tools/irxevent.c 2008-04-17 14:20:15.917788728 -0430 +@@ -133,6 +133,7 @@ + + + static const char *progname="irxevent"; ++static char *lirc_progname = NULL; /* program name to react to, by default irxevent */ + static Display *dpy; + static Window root; + static XEvent xev; +@@ -543,9 +544,10 @@ + + static struct option long_options[] = + { +- {"daemon", no_argument, NULL, 'd'}, +- {"help", no_argument, NULL, 'h'}, +- {"version", no_argument, NULL, 'V'}, ++ {"daemon", no_argument, NULL, 'd'}, ++ {"name", required_argument, NULL, 'n'}, ++ {"help", no_argument, NULL, 'h'}, ++ {"version", no_argument, NULL, 'V'}, + {0, 0, 0, 0} + }; + +@@ -559,13 +561,16 @@ + int c; + int WindowID; + +- while ((c = getopt_long(argc, argv, "dhV", long_options, NULL)) != EOF) { ++ while ((c = getopt_long(argc, argv, "dn:hV", long_options, NULL)) != EOF) { + switch (c) { + case 'd': + bDaemon = 1; continue; ++ case 'n': ++ lirc_progname = optarg; continue; + case 'h': + printf("Usage: %s [option]... [config file]\n" + " -d --daemon fork and run in background\n" ++ " -n --name use this program name\n" + " -h --help display usage summary\n" + " -V --version display version\n", progname); + return(EXIT_SUCCESS); +@@ -597,7 +602,7 @@ + // windows may get closed at wrong time. Override default error handler... + XSetErrorHandler(errorHandler); + +- if(lirc_init("irxevent",1)==-1) exit(EXIT_FAILURE); ++ if(lirc_init(lirc_progname?lirc_progname:progname,1)==-1) exit(EXIT_FAILURE); + + if(lirc_readconfig(config_file,&config,check)==0) + { diff --git a/lirc/lircd b/lirc/lircd new file mode 100755 index 000000000..8b2fd3f4c --- /dev/null +++ b/lirc/lircd @@ -0,0 +1,25 @@ +#!/bin/bash +# +# /etc/rc.d/lircd: start/stop/restart lirc daemon +# + +case "$1" in + start) + /usr/sbin/lircd -p 666 /etc/lircd.conf + ;; + stop) + if [ -f /var/run/lircd.pid ]; then + kill `cat /var/run/lircd.pid` && rm -f /var/run/lircd.pid + else + return 1 + fi + ;; + restart) + $0 stop + $0 start + ;; + *) + echo "Usage: $0 start|stop|restart" + exit 1 + ;; +esac