mirror of
https://github.com/archr-linux/Arch-R.git
synced 2026-03-31 14:41:55 -07:00
lirc: update to 0.9.4
This commit is contained in:
@@ -17,13 +17,13 @@
|
||||
################################################################################
|
||||
|
||||
PKG_NAME="lirc"
|
||||
PKG_VERSION="0.9.0"
|
||||
PKG_VERSION="0.9.4"
|
||||
PKG_REV="1"
|
||||
PKG_ARCH="any"
|
||||
PKG_LICENSE="GPL"
|
||||
PKG_SITE="http://www.lirc.org"
|
||||
PKG_URL="$SOURCEFORGE_SRC/lirc/$PKG_NAME-$PKG_VERSION.tar.bz2"
|
||||
PKG_DEPENDS_TARGET="toolchain libftdi1 libusb-compat"
|
||||
PKG_DEPENDS_TARGET="toolchain libftdi1 libusb-compat libxslt"
|
||||
PKG_PRIORITY="optional"
|
||||
PKG_SECTION="sysutils/remote"
|
||||
PKG_SHORTDESC="lirc: Linux Infrared Remote Control"
|
||||
@@ -35,25 +35,20 @@ PKG_AUTORECONF="yes"
|
||||
PKG_CONFIGURE_OPTS_TARGET="ac_cv_path_LIBUSB_CONFIG= /
|
||||
ac_cv_func_forkpty=no \
|
||||
ac_cv_lib_util_forkpty=no \
|
||||
ac_cv_prog_HAVE_PYTHON3=no \
|
||||
--localstatedir=/ \
|
||||
--enable-sandboxed \
|
||||
--with-gnu-ld \
|
||||
--without-x \
|
||||
--with-driver=userspace \
|
||||
--with-syslog=LOG_DAEMON"
|
||||
|
||||
if [ "$DEBUG" = yes ]; then
|
||||
PKG_CONFIGURE_OPTS_TARGET="$PKG_CONFIGURE_OPTS_TARGET --enable-debug"
|
||||
else
|
||||
PKG_CONFIGURE_OPTS_TARGET="$PKG_CONFIGURE_OPTS_TARGET --disable-debug"
|
||||
fi
|
||||
|
||||
pre_make_target() {
|
||||
export MAKEFLAGS=-j1
|
||||
}
|
||||
--without-x"
|
||||
|
||||
post_makeinstall_target() {
|
||||
rm -rf $INSTALL/usr/bin/pronto2lirc
|
||||
rm -rf $INSTALL/usr/bin/lirc-setup
|
||||
rm -rf $INSTALL/usr/sbin/lircd-setup
|
||||
rm -rf $INSTALL/usr/lib/python3.4
|
||||
rm -rf $INSTALL/usr/lib/systemd
|
||||
rm -rf $INSTALL/lib
|
||||
rm -rf $INSTALL/usr/share
|
||||
rm -rf $INSTALL/etc
|
||||
|
||||
mkdir -p $INSTALL/etc/lirc
|
||||
cp $PKG_DIR/config/lircd.conf.* $INSTALL/etc/lirc
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -1,22 +0,0 @@
|
||||
diff -Naur lirc-0.9.0-old/drivers/lirc_serial/lirc_serial.c lirc-0.9.0-new/drivers/lirc_serial/lirc_serial.c
|
||||
--- lirc-0.9.0-old/drivers/lirc_serial/lirc_serial.c 2011-03-25 15:28:18.000000000 -0700
|
||||
+++ lirc-0.9.0-new/drivers/lirc_serial/lirc_serial.c 2012-06-10 14:18:21.000000000 -0700
|
||||
@@ -66,7 +66,6 @@
|
||||
#include <linux/poll.h>
|
||||
#include <linux/platform_device.h>
|
||||
|
||||
-#include <asm/system.h>
|
||||
#include <linux/io.h>
|
||||
#include <linux/irq.h>
|
||||
#include <linux/fcntl.h>
|
||||
diff -Naur lirc-0.9.0-old/drivers/lirc_sir/lirc_sir.c lirc-0.9.0-new/drivers/lirc_sir/lirc_sir.c
|
||||
--- lirc-0.9.0-old/drivers/lirc_sir/lirc_sir.c 2011-03-25 15:28:18.000000000 -0700
|
||||
+++ lirc-0.9.0-new/drivers/lirc_sir/lirc_sir.c 2012-06-10 14:18:42.000000000 -0700
|
||||
@@ -59,7 +59,6 @@
|
||||
#include <linux/mm.h>
|
||||
#include <linux/delay.h>
|
||||
#include <linux/poll.h>
|
||||
-#include <asm/system.h>
|
||||
#include <linux/io.h>
|
||||
#include <asm/irq.h>
|
||||
#include <linux/fcntl.h>
|
||||
@@ -1,201 +0,0 @@
|
||||
diff -Naur lirc-0.9.0-old/configure.ac lirc-0.9.0-new/configure.ac
|
||||
--- lirc-0.9.0-old/configure.ac 2012-02-29 21:54:01.000000000 -0800
|
||||
+++ lirc-0.9.0-new/configure.ac 2012-02-29 21:55:06.000000000 -0800
|
||||
@@ -164,7 +164,6 @@
|
||||
(lirc_dev lirc_atiusb) \
|
||||
(lirc_dev lirc_bt829) \
|
||||
(lirc_dev lirc_gpio) \
|
||||
- (lirc_dev lirc_i2c) \
|
||||
(lirc_dev lirc_igorplugusb) \
|
||||
(lirc_dev lirc_ttusbir) \
|
||||
(lirc_dev lirc_imon) \
|
||||
@@ -420,32 +419,31 @@
|
||||
AC_ARG_WITH(driver,
|
||||
[ --with-driver=X specify the driver to use, where X is one of:
|
||||
all, none, userspace, accent, act200l,
|
||||
- act220l, adaptec, alsa_usb, animax, asusdh,
|
||||
+ act220l, alsa_usb, animax, asusdh,
|
||||
atilibusb, atiusb, atwf83, audio, audio_alsa
|
||||
avermedia, avermedia_vdomate, avermedia98,
|
||||
- awlibusb, bestbuy, bestbuy2, breakoutbox,
|
||||
+ awlibusb, bestbuy, bestbuy2,
|
||||
bte, bw6130, caraca, chronos, commandir,
|
||||
comX, cph06x, creative, creative_infracd,
|
||||
devinput, dfclibusb, digimatrix, dsp, dvico, ea65,
|
||||
exaudio, flyvideo, ftdi, gvbctv5pci,
|
||||
- hauppauge, hauppauge_dvb,
|
||||
- hercules_smarttv_stereo, i2cuser,
|
||||
+ i2cuser,
|
||||
igorplugusb, iguanaIR, imon, imon_24g,
|
||||
imon_knob, imon_lcd, imon_pad, imon_rsc,
|
||||
irdeo, irdeo_remote, irlink, irman, irreal,
|
||||
- knc_one, kworld,
|
||||
- leadtek_0007, leadtek_0010, leadtek_pvr2000,
|
||||
+ kworld,
|
||||
+ leadtek_0007, leadtek_0010,
|
||||
livedrive_midi, livedrive_seq, logitech,
|
||||
lptX, macmini, mediafocusI,
|
||||
mouseremote, mouseremote_ps2, mp3anywhere,
|
||||
mplay, nslu2,packard_bell, parallel, pcmak,
|
||||
- pcmak_usb, pctv, pixelview_bt878,
|
||||
- pixelview_pak, pixelview_pro, provideo,
|
||||
+ pcmak_usb, pctv,
|
||||
+ pixelview_pak, pixelview_pro,
|
||||
realmagic, remotemaster, sa1100, samsung,
|
||||
sasem, sb0540, serial, silitek, sir, slinke,
|
||||
srm7500libusb, tekram,
|
||||
tekram_bt829, tira, tira_raw, ttusbir,
|
||||
- tuxbox, tvbox, udp, uirt2, uirt2_raw,
|
||||
+ tuxbox, udp, uirt2, uirt2_raw,
|
||||
usb_uirt_raw, usbx, wpc8769l],
|
||||
driver=${withval},
|
||||
driver="unset"
|
||||
@@ -592,9 +590,6 @@
|
||||
lirc_dev-lirc_gpio)
|
||||
#lirc_driver="${lirc_driver} lirc_dev lirc_gpio"
|
||||
;;
|
||||
- lirc_dev-lirc_i2c)
|
||||
- #lirc_driver="${lirc_driver} lirc_dev lirc_i2c"
|
||||
- ;;
|
||||
lirc_dev-lirc_igorplugusb)
|
||||
;;
|
||||
lirc_dev-lirc_ttusbir)
|
||||
@@ -721,12 +716,6 @@
|
||||
AC_DEFINE(LIRC_SIR_ACTISYS_ACT220L)
|
||||
fi
|
||||
|
||||
-if test "$driver" = "adaptec"; then
|
||||
- lirc_driver="lirc_dev lirc_i2c"
|
||||
- lircd_conf="adaptec/lircd.conf.AVC-2410"
|
||||
-# lircmd_conf="adaptec/lircmd.conf.AVC-2410"
|
||||
-fi
|
||||
-
|
||||
if test "$driver" = "alsa_usb"; then
|
||||
lirc_driver="alsa_usb"
|
||||
hw_module="hw_alsa_usb.o"
|
||||
@@ -828,11 +817,6 @@
|
||||
lircmd_conf="bestbuy/lircmd.conf.bestbuy2"
|
||||
fi
|
||||
|
||||
-if test "$driver" = "breakoutbox"; then
|
||||
- lirc_driver="lirc_dev lirc_i2c"
|
||||
- lircd_conf="creative/lircd.conf.breakoutbox"
|
||||
-fi
|
||||
-
|
||||
if test "$driver" = "bte"; then
|
||||
lirc_driver="none"
|
||||
hw_module="hw_bte.o serial.o"
|
||||
@@ -983,23 +967,6 @@
|
||||
# lircmd_conf="iodata/lircmd.conf.gvbctv5pci"
|
||||
fi
|
||||
|
||||
-if test "$driver" = "hauppauge"; then
|
||||
- lirc_driver="lirc_dev lirc_i2c"
|
||||
- lircd_conf="hauppauge/lircd.conf.hauppauge"
|
||||
- lircmd_conf="hauppauge/lircmd.conf.hauppauge"
|
||||
-fi
|
||||
-
|
||||
-if test "$driver" = "hauppauge_dvb"; then
|
||||
- lirc_driver="lirc_dev"
|
||||
- lircd_conf="hauppauge/lircd.conf.hauppauge"
|
||||
- lircmd_conf="hauppauge/lircmd.conf.hauppauge"
|
||||
-fi
|
||||
-
|
||||
-if test "$driver" = "hercules_smarttv_stereo"; then
|
||||
- lirc_driver="lirc_dev lirc_i2c"
|
||||
- lircd_conf="hercules/lircd.conf.smarttv_stereo"
|
||||
-fi
|
||||
-
|
||||
if test "$driver" = "i2cuser"; then
|
||||
lirc_driver="none"
|
||||
hw_module="hw_i2cuser.o receive.o"
|
||||
@@ -1084,12 +1051,6 @@
|
||||
HW_DEFAULT="hw_irreal"
|
||||
fi
|
||||
|
||||
-if test "$driver" = "knc_one"; then
|
||||
- lirc_driver="lirc_dev lirc_i2c"
|
||||
- lircd_conf="knc_one/lircd.conf.knc_one"
|
||||
-# lircmd_conf="knc_one/lircmd.conf.knc_one"
|
||||
-fi
|
||||
-
|
||||
if test "$driver" = "kworld"; then
|
||||
lirc_driver="lirc_dev lirc_gpio"
|
||||
lircd_conf="kworld/lircd.conf.kworld"
|
||||
@@ -1108,12 +1069,6 @@
|
||||
lircmd_conf="leadtek/lircmd.conf.RM-0010"
|
||||
fi
|
||||
|
||||
-if test "$driver" = "leadtek_pvr2000"; then
|
||||
- lirc_driver="lirc_dev lirc_i2c"
|
||||
- lircd_conf="leadtek/lircd.conf.PVR2000"
|
||||
-# lircmd_conf="leadtek/lircmd.conf.PVR2000"
|
||||
-fi
|
||||
-
|
||||
if test "$driver" = "livedrive_midi"; then
|
||||
lirc_driver="none"
|
||||
hw_module="hw_livedrive_common.o hw_livedrive_midi.o"
|
||||
@@ -1230,12 +1185,6 @@
|
||||
# lircmd_conf="pinnacle_systems/lircmd.conf.pctv"
|
||||
fi
|
||||
|
||||
-if test "$driver" = "pixelview_bt878"; then
|
||||
- lirc_driver="lirc_dev lirc_i2c"
|
||||
- lircd_conf="pixelview/lircd.conf.playtv_bt878"
|
||||
-# lircmd_conf="pixelview/lircmd.conf.pixelview_bt878"
|
||||
-fi
|
||||
-
|
||||
if test "$driver" = "pixelview_pak"; then
|
||||
lirc_driver="lirc_dev lirc_gpio"
|
||||
# the config files are the same as for the PlayTV pro
|
||||
@@ -1249,12 +1198,6 @@
|
||||
lircmd_conf="pixelview/lircmd.conf.playtv_pro"
|
||||
fi
|
||||
|
||||
-if test "$driver" = "provideo"; then
|
||||
- lirc_driver="lirc_dev lirc_i2c"
|
||||
- lircd_conf="provideo/lircd.conf.pv951"
|
||||
-# lircmd_conf="provideo/lircmd.conf.pv951"
|
||||
-fi
|
||||
-
|
||||
if test "$driver" = "realmagic"; then
|
||||
lirc_driver="none"
|
||||
hw_module="hw_pixelview.o serial.o"
|
||||
@@ -1372,11 +1315,6 @@
|
||||
HW_DEFAULT="hw_default"
|
||||
fi
|
||||
|
||||
-if test "$driver" = "tvbox"; then
|
||||
- lirc_driver="lirc_dev lirc_i2c"
|
||||
- lircd_conf="asus/lircd.conf.asus"
|
||||
-fi
|
||||
-
|
||||
if test "$driver" = "udp"; then
|
||||
lirc_driver="none"
|
||||
hw_module="hw_udp.o receive.o"
|
||||
@@ -1512,7 +1450,6 @@
|
||||
lirc_driver="lirc_dev \
|
||||
lirc_atiusb \
|
||||
lirc_bt829 \
|
||||
- lirc_i2c \
|
||||
lirc_igorplugusb \
|
||||
lirc_imon \
|
||||
lirc_parallel \
|
||||
@@ -1779,7 +1716,6 @@
|
||||
drivers/lirc_bt829/Makefile
|
||||
drivers/lirc_dev/Makefile
|
||||
drivers/lirc_gpio/Makefile
|
||||
- drivers/lirc_i2c/Makefile
|
||||
drivers/lirc_igorplugusb/Makefile
|
||||
drivers/lirc_ttusbir/Makefile
|
||||
drivers/lirc_imon/Makefile
|
||||
@@ -1808,9 +1744,6 @@
|
||||
elif test "$driver" = "alsa_usb"; then
|
||||
echo "You will have to use the snd-usb-audio driver from:"
|
||||
echo "http://www.alsa-project.org/"
|
||||
-elif test "$driver" = "hauppauge_dvb"; then
|
||||
- echo "You will have to use the DVB driver from:"
|
||||
- echo "http://www.linuxtv.org"
|
||||
elif test "$kernel_module" = ""; then
|
||||
echo "Your hardware does not require a special LIRC kernel module."
|
||||
if test "${irtty}" != ""; then
|
||||
@@ -1,33 +0,0 @@
|
||||
diff -Naur lirc-0.9.0-old-old/drivers/lirc_atiusb/lirc_atiusb.c lirc-0.9.0-old-new/drivers/lirc_atiusb/lirc_atiusb.c
|
||||
--- lirc-0.9.0-old-old/drivers/lirc_atiusb/lirc_atiusb.c 2012-05-01 12:09:19.000000000 -0700
|
||||
+++ lirc-0.9.0-old-new/drivers/lirc_atiusb/lirc_atiusb.c 2012-05-01 12:14:52.000000000 -0700
|
||||
@@ -138,23 +138,23 @@
|
||||
|
||||
static struct usb_device_id usb_remote_table[] = {
|
||||
/* X10 USB Firecracker Interface */
|
||||
- { USB_DEVICE(VENDOR_ATI1, 0x0002) },
|
||||
+ /* { USB_DEVICE(VENDOR_ATI1, 0x0002) }, */
|
||||
|
||||
/* X10 VGA Video Sender */
|
||||
- { USB_DEVICE(VENDOR_ATI1, 0x0003) },
|
||||
+ /* { USB_DEVICE(VENDOR_ATI1, 0x0003) }, */
|
||||
|
||||
/* ATI Wireless Remote Receiver */
|
||||
- { USB_DEVICE(VENDOR_ATI1, 0x0004) },
|
||||
+ /* { USB_DEVICE(VENDOR_ATI1, 0x0004) }, */
|
||||
|
||||
/* NVIDIA Wireless Remote Receiver */
|
||||
- { USB_DEVICE(VENDOR_ATI1, 0x0005) },
|
||||
+ /* { USB_DEVICE(VENDOR_ATI1, 0x0005) }, */
|
||||
|
||||
/* ATI Wireless Remote Receiver */
|
||||
- { USB_DEVICE(VENDOR_ATI1, 0x0006) },
|
||||
+ /* { USB_DEVICE(VENDOR_ATI1, 0x0006) }, */
|
||||
|
||||
/* X10 USB Wireless Transceivers */
|
||||
{ USB_DEVICE(VENDOR_ATI1, 0x0007) },
|
||||
- { USB_DEVICE(VENDOR_ATI1, 0x0008) },
|
||||
+ /* { USB_DEVICE(VENDOR_ATI1, 0x0008) }, */
|
||||
{ USB_DEVICE(VENDOR_ATI1, 0x0009) },
|
||||
{ USB_DEVICE(VENDOR_ATI1, 0x000A) },
|
||||
{ USB_DEVICE(VENDOR_ATI1, 0x000B) },
|
||||
@@ -1,11 +0,0 @@
|
||||
diff -Naur lirc-0.9.0-old/drivers/lirc_atiusb/lirc_atiusb.c lirc-0.9.0-new/drivers/lirc_atiusb/lirc_atiusb.c
|
||||
--- lirc-0.9.0-old/drivers/lirc_atiusb/lirc_atiusb.c 2011-07-27 20:45:01.000000000 -0700
|
||||
+++ lirc-0.9.0-new/drivers/lirc_atiusb/lirc_atiusb.c 2011-07-27 20:45:53.000000000 -0700
|
||||
@@ -48,7 +48,6 @@
|
||||
#include <linux/slab.h>
|
||||
#include <linux/module.h>
|
||||
#include <linux/kmod.h>
|
||||
-#include <linux/smp_lock.h>
|
||||
#include <linux/completion.h>
|
||||
#include <linux/uaccess.h>
|
||||
#include <linux/usb.h>
|
||||
@@ -1,29 +0,0 @@
|
||||
diff -Naur lirc-0.9.0-old/drivers/lirc_wpc8769l/lirc_wpc8769l.c lirc-0.9.0-new/drivers/lirc_wpc8769l/lirc_wpc8769l.c
|
||||
--- lirc-0.9.0-old/drivers/lirc_wpc8769l/lirc_wpc8769l.c 2011-07-27 20:45:36.000000000 -0700
|
||||
+++ lirc-0.9.0-new/drivers/lirc_wpc8769l/lirc_wpc8769l.c 2011-07-27 20:46:22.000000000 -0700
|
||||
@@ -361,14 +361,14 @@
|
||||
size = count << 3;
|
||||
|
||||
ldata = (unsigned long *) data_buf;
|
||||
- next_one = generic_find_next_le_bit(ldata, size, 0);
|
||||
+ next_one = find_next_bit_le(ldata, size, 0);
|
||||
|
||||
if (next_one > 0)
|
||||
put_pulse_bit(next_one
|
||||
* WPC8769L_USECS_PER_BIT);
|
||||
|
||||
while (next_one < size) {
|
||||
- next_zero = generic_find_next_zero_le_bit(ldata,
|
||||
+ next_zero = find_next_zero_bit_le(ldata,
|
||||
size, next_one + 1);
|
||||
|
||||
put_space_bit(
|
||||
@@ -376,7 +376,7 @@
|
||||
* WPC8769L_USECS_PER_BIT);
|
||||
|
||||
if (next_zero < size) {
|
||||
- next_one = generic_find_next_le_bit(ldata,
|
||||
+ next_one = find_next_bit_le(ldata,
|
||||
size, next_zero + 1);
|
||||
|
||||
put_pulse_bit(
|
||||
@@ -1,63 +0,0 @@
|
||||
diff -Naur lirc-0.9.0-old/daemons/input_map.c lirc-0.9.0-new/daemons/input_map.c
|
||||
--- lirc-0.9.0-old/daemons/input_map.c 2011-07-27 20:46:13.000000000 -0700
|
||||
+++ lirc-0.9.0-new/daemons/input_map.c 2011-07-27 20:47:15.000000000 -0700
|
||||
@@ -25,6 +25,19 @@
|
||||
NULL, 0}
|
||||
};
|
||||
|
||||
+int get_input_code_by_index(int index, linux_input_code * code)
|
||||
+{
|
||||
+ int i;
|
||||
+
|
||||
+ for (i = 0; input_map[i].name != NULL; i++) {
|
||||
+ if (i == index) {
|
||||
+ *code = input_map[i].code;
|
||||
+ return i;
|
||||
+ }
|
||||
+ }
|
||||
+ return -1;
|
||||
+}
|
||||
+
|
||||
int get_input_code(const char *name, linux_input_code * code)
|
||||
{
|
||||
int i;
|
||||
diff -Naur lirc-0.9.0-old/daemons/input_map.h lirc-0.9.0-new/daemons/input_map.h
|
||||
--- lirc-0.9.0-old/daemons/input_map.h 2011-07-27 20:46:13.000000000 -0700
|
||||
+++ lirc-0.9.0-new/daemons/input_map.h 2011-07-27 20:47:15.000000000 -0700
|
||||
@@ -28,6 +28,7 @@
|
||||
typedef unsigned short linux_input_code;
|
||||
#endif
|
||||
|
||||
+int get_input_code_by_index(int index, linux_input_code * code);
|
||||
int get_input_code(const char *name, linux_input_code * code);
|
||||
void fprint_namespace(FILE * f);
|
||||
int is_in_namespace(const char *name);
|
||||
diff -Naur lirc-0.9.0-old/daemons/lircd.c lirc-0.9.0-new/daemons/lircd.c
|
||||
--- lirc-0.9.0-old/daemons/lircd.c 2011-07-27 20:46:13.000000000 -0700
|
||||
+++ lirc-0.9.0-new/daemons/lircd.c 2011-07-27 20:47:15.000000000 -0700
|
||||
@@ -406,6 +406,8 @@
|
||||
#if defined(__linux__)
|
||||
int fd;
|
||||
int key;
|
||||
+ linux_input_code code;
|
||||
+ int i;
|
||||
struct uinput_user_dev dev;
|
||||
|
||||
fd = open("/dev/input/uinput", O_RDWR);
|
||||
@@ -428,9 +430,13 @@
|
||||
goto setup_error;
|
||||
}
|
||||
|
||||
- for (key = KEY_RESERVED; key <= KEY_UNKNOWN; key++) {
|
||||
- if (ioctl(fd, UI_SET_KEYBIT, key) != 0) {
|
||||
- goto setup_error;
|
||||
+ for(i = 0; get_input_code_by_index(i, &code) >= 0; i++) {
|
||||
+ key = (int)code;
|
||||
+ if (((key >= KEY_ESC) && (key <= KEY_RFKILL )) ||
|
||||
+ ((key >= KEY_OK ) && (key <= KEY_WPS_BUTTON))) {
|
||||
+ if (ioctl(fd, UI_SET_KEYBIT, key) != 0) {
|
||||
+ goto setup_error;
|
||||
+ }
|
||||
}
|
||||
}
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -1,48 +0,0 @@
|
||||
From 4022c521c26e339152c6cc8febd6d737725de8ee Mon Sep 17 00:00:00 2001
|
||||
From: Stefan Saraev <stefan@saraev.ca>
|
||||
Date: Wed, 22 Jan 2014 15:59:14 +0200
|
||||
Subject: [PATCH] meh alsa...
|
||||
|
||||
---
|
||||
configure.ac | 25 -------------------------
|
||||
1 files changed, 0 insertions(+), 25 deletions(-)
|
||||
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index 73a353f..74ccba8 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -342,31 +342,6 @@ AC_CHECK_HEADERS(portaudio.h,[
|
||||
],,${portaudio_lib_other}
|
||||
)]
|
||||
)
|
||||
-dnl audio_alsa driver requires ALSA library installed and some linker flags
|
||||
-have_alsa=no
|
||||
-AC_CHECK_HEADERS(alsa/asoundlib.h,[
|
||||
- AC_CHECK_LIB(asound, snd_pcm_open,[
|
||||
- AC_DEFINE(HAVE_LIBALSA)
|
||||
- have_alsa=yes
|
||||
- possible_drivers="${possible_drivers} (audio_alsa)"
|
||||
- ],,
|
||||
- )]
|
||||
-)
|
||||
-dnl alsa_usb driver requires an ALSA that knows about our hwdep device
|
||||
-if test "$have_alsa" = "yes"; then
|
||||
- AC_MSG_CHECKING(for ALSA SB RC hwdep support)
|
||||
- AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
|
||||
-#include <alsa/asoundlib.h>
|
||||
-]], [[
|
||||
- if (snd_hwdep_info_get_iface(NULL) == SND_HWDEP_IFACE_SB_RC) {}
|
||||
-]])],[
|
||||
- AC_MSG_RESULT(yes)
|
||||
- AC_DEFINE(HAVE_ALSA_SB_RC)
|
||||
- possible_drivers="${possible_drivers} (alsa_usb)"
|
||||
- ],[
|
||||
- AC_MSG_RESULT(no)
|
||||
- ])
|
||||
-fi
|
||||
dnl creative_infracd driver requires linux scsi api
|
||||
AC_CHECK_HEADERS(scsi/sg.h,[
|
||||
AC_DEFINE(HAVE_SCSI)
|
||||
--
|
||||
1.7.2.5
|
||||
|
||||
@@ -1,70 +0,0 @@
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index 74ccba8..e40f51a 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -318,7 +318,7 @@ AC_CHECK_HEADER(usb.h,
|
||||
AC_DEFINE(HAVE_LIBUSB)
|
||||
possible_drivers="${possible_drivers} (atilibusb) (awlibusb) (dfclibusb) (commandir) (srm7500libusb)"
|
||||
)
|
||||
-AC_CHECK_HEADER(ftdi.h,
|
||||
+AC_CHECK_HEADER(libftdi1/ftdi.h,
|
||||
AC_DEFINE(HAVE_FTDI)
|
||||
possible_drivers="${possible_drivers} (ftdi)"
|
||||
)
|
||||
@@ -533,7 +533,7 @@ if test "$driver" = "userspace" -o "$driver" = "all"; then
|
||||
;;
|
||||
ftdi)
|
||||
hw_module="${hw_module} hw_ftdi.o receive.o transmit.o"
|
||||
- ftdi_lib="-lftdi"
|
||||
+ ftdi_lib="-lftdi1"
|
||||
;;
|
||||
i2cuser)
|
||||
hw_module="${hw_module} hw_i2cuser.o receive.o"
|
||||
@@ -934,7 +934,7 @@ if test "$driver" = "ftdi"; then
|
||||
lirc_driver="none"
|
||||
hw_module="hw_ftdi.o receive.o transmit.o"
|
||||
HW_DEFAULT="hw_ftdi"
|
||||
- ftdi_lib="-lftdi"
|
||||
+ ftdi_lib="-lftdi1"
|
||||
fi
|
||||
|
||||
if test "$driver" = "gvbctv5pci"; then
|
||||
diff --git a/daemons/hw_ftdi.c b/daemons/hw_ftdi.c
|
||||
index d867bc9..e5ef563 100644
|
||||
--- a/daemons/hw_ftdi.c
|
||||
+++ b/daemons/hw_ftdi.c
|
||||
@@ -51,7 +51,7 @@
|
||||
#include "transmit.h"
|
||||
#include "hw_default.h"
|
||||
|
||||
-#include <ftdi.h>
|
||||
+#include <libftdi1/ftdi.h>
|
||||
|
||||
/* PID of the child process */
|
||||
static pid_t child_pid = -1;
|
||||
@@ -62,6 +62,7 @@ static pid_t child_pid = -1;
|
||||
static char *device_config = NULL;
|
||||
static int tx_baud_rate = 65536;
|
||||
static int rx_baud_rate = 9600;
|
||||
+static int rx_sample_rate = 16;
|
||||
static int input_pin = 1; /* RXD as input */
|
||||
static int output_pin = 2; /* RTS as output */
|
||||
static int usb_vendor = 0x0403; /* default for FT232 */
|
||||
@@ -94,7 +95,7 @@ static void parsesamples(unsigned char *buf, int n, int pipe_rxir_w)
|
||||
* The datasheet indicates that the sample rate in
|
||||
* bitbang mode is 16 times the baud rate but 32 seems
|
||||
* to be correct. */
|
||||
- usecs = (rxctr * 1000000LL) / (rx_baud_rate * 32);
|
||||
+ usecs = (rxctr * 1000000LL) / (rx_baud_rate * rx_sample_rate);
|
||||
|
||||
/* Clamp */
|
||||
if (usecs > PULSE_MASK) {
|
||||
@@ -142,7 +143,7 @@ static void child_process(int fd_rx2main, int fd_main2tx, int fd_tx2main)
|
||||
|
||||
/* Enable bit-bang mode, setting output & input pins
|
||||
direction */
|
||||
- if (ftdi_enable_bitbang(&ftdic, 1 << output_pin) < 0) {
|
||||
+ if (ftdi_set_bitmode(&ftdic, 1 << output_pin, BITMODE_BITBANG) < 0) {
|
||||
logprintf(LOG_ERR, "unable to enable bitbang mode (%s)", ftdi_get_error_string(&ftdic));
|
||||
goto retry;
|
||||
}
|
||||
@@ -1,12 +0,0 @@
|
||||
diff -Naur lirc-0.9.0-old/configure.ac lirc-0.9.0-new/configure.ac
|
||||
--- lirc-0.9.0-old/configure.ac 2011-03-25 15:28:18.000000000 -0700
|
||||
+++ lirc-0.9.0-new/configure.ac 2012-12-31 05:01:51.000000000 -0800
|
||||
@@ -8,7 +8,7 @@
|
||||
AC_CONFIG_MACRO_DIR([m4])
|
||||
|
||||
AM_INIT_AUTOMAKE(lirc, 0.9.1-git)
|
||||
-AM_CONFIG_HEADER(config.h)
|
||||
+AC_CONFIG_HEADERS(config.h)
|
||||
|
||||
CFLAGS="${CFLAGS--O2 -g -Wall}"
|
||||
|
||||
@@ -0,0 +1,12 @@
|
||||
diff -Naur a/configure.ac b/configure.ac
|
||||
--- a/configure.ac 2016-05-23 10:18:48.000000000 -0700
|
||||
+++ b/configure.ac 2016-06-08 02:09:11.335251580 -0700
|
||||
@@ -33,7 +33,7 @@
|
||||
AC_MSG_ERROR([
|
||||
xsltproc is required to build. It usually comes with libxml])
|
||||
fi
|
||||
-AM_CONDITIONAL(HAVE_UINPUT, test -e /dev/uinput)
|
||||
+AM_CONDITIONAL(HAVE_UINPUT, true)
|
||||
AC_CHECK_PROG([MAN2HTML],[man2html],[yes],[no])
|
||||
AM_CONDITIONAL(HAVE_MAN2HTML, test x$MAN2HTML = xyes)
|
||||
AC_CHECK_PROG([DOXYGEN],[doxygen],[yes],[no])
|
||||
@@ -0,0 +1,38 @@
|
||||
diff -Naur a/configure.ac b/configure.ac
|
||||
--- a/configure.ac 2016-06-08 13:06:09.757102470 -0700
|
||||
+++ b/configure.ac 2016-06-08 13:07:04.620705345 -0700
|
||||
@@ -41,8 +41,8 @@
|
||||
AC_PROG_LN_S
|
||||
LT_INIT([disable-static])
|
||||
AM_PATH_PYTHON([3.1],,)
|
||||
-AM_CONDITIONAL([HAVE_PYTHON], [test "$PYTHON" != ""])
|
||||
-AC_CHECK_PROG([HAVE_PYTHON3],[python3],[yes],[no])
|
||||
+AM_CONDITIONAL([HAVE_PYTHON], [test "$PYTHON" == ""])
|
||||
+AC_CHECK_PROG([HAVE_PYTHON3],[python3],[no],[no])
|
||||
LIBUSB_CONFIG="pkg-config libusb"
|
||||
|
||||
dnl Checks for header files.
|
||||
diff -Naur a/tools/Makefile.am b/tools/Makefile.am
|
||||
--- a/tools/Makefile.am 2016-05-23 10:18:48.000000000 -0700
|
||||
+++ b/tools/Makefile.am 2016-06-08 13:15:25.711341537 -0700
|
||||
@@ -114,19 +114,12 @@
|
||||
|
||||
install-exec-hook:
|
||||
$(SED) -i -e 's/@version@/$(VERSION)/' \
|
||||
- $(DESTDIR)$(bindir)/lirc-config-tool \
|
||||
- $(DESTDIR)$(bindir)/irdb-get
|
||||
+ $(DESTDIR)$(bindir)/lirc-config-tool
|
||||
rm -f $(DESTDIR)/$(bindir)/lirc-setup
|
||||
$(srcdir)/make_rel_symlink.py \
|
||||
$(DESTDIR)/$(pkgpythondir)/lirc-setup \
|
||||
$(DESTDIR)/$(bindir)/lirc-setup
|
||||
|
||||
-install-data-hook:
|
||||
- rm -f $(DESTDIR)/$(pkgpythondir)/configs
|
||||
- $(srcdir)/make_rel_symlink.py \
|
||||
- $(DESTDIR)$(pkgdatadir)/configs \
|
||||
- $(DESTDIR)$(pkgpythondir)/configs
|
||||
-
|
||||
uninstall-hook:
|
||||
rm -f $(DESTDIR)/$(bindir)/lirc-setup \
|
||||
$(DESTDIR)/$(pkgpythondir)/configs
|
||||
@@ -0,0 +1,28 @@
|
||||
--- a/lib/Makefile.am
|
||||
+++ b/lib/Makefile.am
|
||||
@@ -29,7 +29,7 @@
|
||||
transmit.c \
|
||||
util.c
|
||||
|
||||
-libirrecord_la_LDFLAGS = -llirc
|
||||
+libirrecord_la_LIBADD = -llirc
|
||||
libirrecord_la_SOURCES = irrecord.c
|
||||
|
||||
liblirc_client_la_LDFLAGS = -version-info 4:0:4
|
||||
@@ -98,10 +98,16 @@
|
||||
|
||||
input_map.inc: lirc/input_map.inc
|
||||
|
||||
+if BSD
|
||||
+lirc/input_map.inc:
|
||||
+ touch $@
|
||||
+ touch touch input_map.inc
|
||||
+else
|
||||
lirc/input_map.inc:
|
||||
ln -s . lirc || :
|
||||
$(top_srcdir)/tools/lirc-make-devinput -i > input_map.inc
|
||||
$(top_srcdir)/tools/lirc-make-devinput -i > $@
|
||||
+endif
|
||||
|
||||
checkfiles:
|
||||
../git-tools/checkfiles $(SOURCES) $(HEADERS)
|
||||
@@ -0,0 +1,110 @@
|
||||
--- a/daemons/lircd.cpp
|
||||
+++ b/daemons/lircd.cpp
|
||||
@@ -901,43 +901,41 @@
|
||||
{
|
||||
int r;
|
||||
char service[64];
|
||||
- struct addrinfo* addr;
|
||||
- struct addrinfo* tmp;
|
||||
+ struct addrinfo* addrinfos;
|
||||
+ struct addrinfo* a;
|
||||
int enable = 1;
|
||||
|
||||
snprintf(service, sizeof(service), "%d", peer->port);
|
||||
peer->socket = socket(AF_INET, SOCK_STREAM, 0);
|
||||
- r = getaddrinfo(peer->host, service, NULL, &addr);
|
||||
+ r = getaddrinfo(peer->host, service, NULL, &addrinfos);
|
||||
if (r != 0) {
|
||||
- log_error("Name lookup failure connecting to %s",
|
||||
- peer->host);
|
||||
- peer->connection_failure++;
|
||||
- gettimeofday(&peer->reconnect, NULL);
|
||||
- peer->reconnect.tv_sec += 5 * peer->connection_failure;
|
||||
- close(peer->socket);
|
||||
- peer->socket = -1;
|
||||
- return;
|
||||
+ log_perror_err("Name lookup failure connecting to %s",
|
||||
+ peer->host);
|
||||
+ goto errexit;
|
||||
}
|
||||
(void)setsockopt(peer->socket,
|
||||
SOL_SOCKET, SO_KEEPALIVE, &enable, sizeof(enable));
|
||||
- do {
|
||||
- r = connect(peer->socket,
|
||||
- addr->ai_addr, sizeof(struct sockaddr));
|
||||
- tmp = addr;
|
||||
- addr = addr->ai_next;
|
||||
- freeaddrinfo(tmp);
|
||||
- } while (r < 0 && addr != NULL);
|
||||
+ for (a = addrinfos; a != NULL; a = a->ai_next) {
|
||||
+ r = connect(peer->socket, a->ai_addr, a->ai_addrlen);
|
||||
+ if (r >= 0)
|
||||
+ break;
|
||||
+ }
|
||||
+ freeaddrinfo(addrinfos);
|
||||
if (r == -1) {
|
||||
log_perror_err("Cannot connect to %s", peer->host);
|
||||
- peer->connection_failure++;
|
||||
- gettimeofday(&peer->reconnect, NULL);
|
||||
- peer->reconnect.tv_sec += 5 * peer->connection_failure;
|
||||
- close(peer->socket);
|
||||
- peer->socket = -1;
|
||||
- return;
|
||||
- }
|
||||
- log_notice("connected to %s", peer->host);
|
||||
+ goto errexit;
|
||||
+ }
|
||||
+ log_notice("Connected to %s", peer->host);
|
||||
peer->connection_failure = 0;
|
||||
+ return;
|
||||
+
|
||||
+errexit:
|
||||
+ peer->connection_failure++;
|
||||
+ gettimeofday(&peer->reconnect, NULL);
|
||||
+ peer->reconnect.tv_sec += 5 * peer->connection_failure;
|
||||
+ close(peer->socket);
|
||||
+ peer->socket = -1;
|
||||
+ return;
|
||||
}
|
||||
|
||||
|
||||
--- a/lib/lirc_client.c
|
||||
+++ b/lib/lirc_client.c
|
||||
@@ -2050,28 +2050,25 @@
|
||||
|
||||
int lirc_get_remote_socket(const char* address, int port, int quiet)
|
||||
{
|
||||
- struct addrinfo* host;
|
||||
- struct addrinfo* tmp;
|
||||
+ struct addrinfo* addrinfos;
|
||||
+ struct addrinfo* a;
|
||||
char service[64];
|
||||
int r;
|
||||
|
||||
snprintf(service, sizeof(service),
|
||||
"%d", port > 0 ? port : LIRC_INET_PORT);
|
||||
- r = getaddrinfo(address, service, NULL, &host);
|
||||
+ r = getaddrinfo(address, service, NULL, &addrinfos);
|
||||
if (r < 0) {
|
||||
if (!quiet)
|
||||
fprintf(stderr, "get_remote_socket: host %s unknown\n",
|
||||
address);
|
||||
return -EADDRNOTAVAIL;
|
||||
}
|
||||
- do {
|
||||
- r = do_connect(host->ai_family,
|
||||
- host->ai_addr,
|
||||
- sizeof(host->ai_addr),
|
||||
- quiet);
|
||||
- tmp = host;
|
||||
- host = host->ai_next;
|
||||
- freeaddrinfo(tmp);
|
||||
- } while (r < 0 && host != NULL);
|
||||
+ for (a = addrinfos; a != NULL; a = a->ai_next) {
|
||||
+ r = do_connect(a->ai_family, a->ai_addr, a->ai_addrlen, quiet);
|
||||
+ if (r >= 0)
|
||||
+ break;
|
||||
+ };
|
||||
+ freeaddrinfo(addrinfos);
|
||||
return r;
|
||||
}
|
||||
12
packages/sysutils/lirc/system.d/lircd-uinput@.service
Normal file
12
packages/sysutils/lirc/system.d/lircd-uinput@.service
Normal file
@@ -0,0 +1,12 @@
|
||||
[Unit]
|
||||
Description=lircd-uinput with %I
|
||||
|
||||
[Service]
|
||||
ExecStart=/usr/sbin/lircd-uinput /run/lirc/lircd-%I
|
||||
Slice=system-lircd.slice
|
||||
Restart=on-failure
|
||||
RestartSec=2
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
|
||||
@@ -63,6 +63,12 @@ ENV{lircd_driver}=="?*", ENV{lircd_conf}=="?*", ACTION=="add", \
|
||||
TAG+="systemd", ENV{SYSTEMD_WANTS}+="lircd@$name:$env{lircd_driver}:$env{lircd_conf}.service", \
|
||||
RUN+="lircd_wakeup_enable"
|
||||
|
||||
ENV{lircd_driver}=="?*", ENV{lircd_conf}=="?*", ACTION=="add", \
|
||||
TAG+="systemd", ENV{SYSTEMD_WANTS}+="lircd-uinput@$name.service"
|
||||
|
||||
ENV{lircd_driver}=="?*", ENV{lircd_conf}=="?*", ACTION=="remove", \
|
||||
RUN+="/usr/bin/systemctl stop lircd-uinput@$name.service"
|
||||
|
||||
ENV{lircd_driver}=="?*", ENV{lircd_conf}=="?*", ACTION=="remove", \
|
||||
RUN+="/usr/bin/systemctl stop lircd@$name:$env{lircd_driver}:$env{lircd_conf}.service"
|
||||
|
||||
|
||||
Reference in New Issue
Block a user