summaryrefslogtreecommitdiff
path: root/comms
diff options
context:
space:
mode:
authorEdwin Groothuis <edwin@FreeBSD.org>2003-10-06 01:31:49 +0000
committerEdwin Groothuis <edwin@FreeBSD.org>2003-10-06 01:31:49 +0000
commit627aa4a08ef1285003c63a0ad8ebe6e2a82064f1 (patch)
treed900613d39b220856e4b1b601b5459fb3cfa0d51 /comms
parentNew port: kix-kmod : Syscons screen saver module (diff)
New port: comms/lirc: Linux Infared Remote Control
This is a port of the LIRC, Linux Infrared Remote Control, package (www.lirc.org). This port installs the daemons and tools for interacting with device drivers that support the LIRC device interface. The port does not install any FreeBSD infrared device drivers yet; the user must obtain these from third parties or port the existing Linux drivers. PR: ports/46774 Submitted by: Mike Heffner <mikeh@FreeBSD.org> <mheffner@acm.vt.edu>
Notes
Notes: svn path=/head/; revision=90343
Diffstat (limited to 'comms')
-rw-r--r--comms/Makefile1
-rw-r--r--comms/lirc/Makefile30
-rw-r--r--comms/lirc/distinfo1
-rw-r--r--comms/lirc/files/patch-aa61
-rw-r--r--comms/lirc/files/patch-ab40
-rw-r--r--comms/lirc/files/patch-ac46
-rw-r--r--comms/lirc/files/patch-ad11
-rw-r--r--comms/lirc/pkg-descr22
-rw-r--r--comms/lirc/pkg-message8
-rw-r--r--comms/lirc/pkg-plist17
10 files changed, 237 insertions, 0 deletions
diff --git a/comms/Makefile b/comms/Makefile
index eb69c992a0de..538dc4bd53bf 100644
--- a/comms/Makefile
+++ b/comms/Makefile
@@ -29,6 +29,7 @@
SUBDIR += kermit
SUBDIR += kpsk
SUBDIR += libticables
+ SUBDIR += lirc
SUBDIR += lrzsz
SUBDIR += ltmdm
SUBDIR += mgetty+sendfax
diff --git a/comms/lirc/Makefile b/comms/lirc/Makefile
new file mode 100644
index 000000000000..a365e07eb3c0
--- /dev/null
+++ b/comms/lirc/Makefile
@@ -0,0 +1,30 @@
+# New ports collection makefile for: lirc
+# Date created: 4 January 2003
+# Whom: Mike Heffner <mikeh@FreeBSD.org>
+#
+# $FreeBSD$
+#
+
+PORTNAME= lirc
+PORTVERSION= 0.6.6
+CATEGORIES= comms
+MASTER_SITES= ${MASTER_SITE_SOURCEFORGE}
+MASTER_SITE_SUBDIR= lirc
+
+MAINTAINER= mikeh@FreeBSD.org
+COMMENT= Linux Infared Remote Control
+
+LIB_DEPENDS= gnugetopt.1:${PORTSDIR}/devel/libgnugetopt
+
+USE_GMAKE= yes
+GNU_CONFIGURE= yes
+CONFIGURE_ARGS+=--with-driver=any --disable-manage-devices
+
+MAN1= irexec.1 ircat.1 irpty.1 irrecord.1 irw.1 irxevent.1 \
+ mode2.1 smode2.1 xmode2.1 rc.1
+MAN8= lircd.8 lircmd.8
+
+post-install:
+ @${CAT} ${PKGMESSAGE}
+
+.include <bsd.port.mk>
diff --git a/comms/lirc/distinfo b/comms/lirc/distinfo
new file mode 100644
index 000000000000..a4a4c4325160
--- /dev/null
+++ b/comms/lirc/distinfo
@@ -0,0 +1 @@
+MD5 (lirc-0.6.6.tar.gz) = 03e200d518c8d07eff94596dbd573350
diff --git a/comms/lirc/files/patch-aa b/comms/lirc/files/patch-aa
new file mode 100644
index 000000000000..4eac8325fac3
--- /dev/null
+++ b/comms/lirc/files/patch-aa
@@ -0,0 +1,61 @@
+--- drivers/lirc.h.orig Sat Jan 4 19:45:07 2003
++++ drivers/lirc.h Sat Jan 4 19:44:24 2003
+@@ -3,9 +3,6 @@
+ #ifndef _LINUX_LIRC_H
+ #define _LINUX_LIRC_H
+
+-#include <asm/types.h>
+-#include <linux/ioctl.h>
+-
+ #define PULSE_BIT 0x01000000
+ #define PULSE_MASK 0x00FFFFFF
+
+@@ -64,32 +61,32 @@
+ * IOCTL commands for lirc driver
+ */
+
+-#define LIRC_GET_FEATURES _IOR('i', 0x00000000, __u32)
++#define LIRC_GET_FEATURES _IOR('i', 0x00000000, u_int32_t)
+
+-#define LIRC_GET_SEND_MODE _IOR('i', 0x00000001, __u32)
+-#define LIRC_GET_REC_MODE _IOR('i', 0x00000002, __u32)
+-#define LIRC_GET_SEND_CARRIER _IOR('i', 0x00000003, __u32)
+-#define LIRC_GET_REC_CARRIER _IOR('i', 0x00000004, __u32)
+-#define LIRC_GET_SEND_DUTY_CYCLE _IOR('i', 0x00000005, __u32)
+-#define LIRC_GET_REC_DUTY_CYCLE _IOR('i', 0x00000006, __u32)
++#define LIRC_GET_SEND_MODE _IOR('i', 0x00000001, u_int32_t)
++#define LIRC_GET_REC_MODE _IOR('i', 0x00000002, u_int32_t)
++#define LIRC_GET_SEND_CARRIER _IOR('i', 0x00000003, u_int32_t)
++#define LIRC_GET_REC_CARRIER _IOR('i', 0x00000004, u_int32_t)
++#define LIRC_GET_SEND_DUTY_CYCLE _IOR('i', 0x00000005, u_int32_t)
++#define LIRC_GET_REC_DUTY_CYCLE _IOR('i', 0x00000006, u_int32_t)
+
+ /* code length in bits, currently only for LIRC_MODE_LIRCCODE */
+-#define LIRC_GET_LENGTH _IOR('i', 0x0000000f, __u32)
++#define LIRC_GET_LENGTH _IOR('i', 0x0000000f, u_int32_t)
+
+-#define LIRC_SET_SEND_MODE _IOW('i', 0x00000011, __u32)
+-#define LIRC_SET_REC_MODE _IOW('i', 0x00000012, __u32)
++#define LIRC_SET_SEND_MODE _IOW('i', 0x00000011, u_int32_t)
++#define LIRC_SET_REC_MODE _IOW('i', 0x00000012, u_int32_t)
+ /* Note: these can reset the according pulse_width */
+-#define LIRC_SET_SEND_CARRIER _IOW('i', 0x00000013, __u32)
+-#define LIRC_SET_REC_CARRIER _IOW('i', 0x00000014, __u32)
+-#define LIRC_SET_SEND_DUTY_CYCLE _IOW('i', 0x00000015, __u32)
+-#define LIRC_SET_REC_DUTY_CYCLE _IOW('i', 0x00000016, __u32)
++#define LIRC_SET_SEND_CARRIER _IOW('i', 0x00000013, u_int32_t)
++#define LIRC_SET_REC_CARRIER _IOW('i', 0x00000014, u_int32_t)
++#define LIRC_SET_SEND_DUTY_CYCLE _IOW('i', 0x00000015, u_int32_t)
++#define LIRC_SET_REC_DUTY_CYCLE _IOW('i', 0x00000016, u_int32_t)
+
+ /* to set a range use
+ LIRC_SET_REC_DUTY_CYCLE_RANGE/LIRC_SET_REC_CARRIER_RANGE with the
+ lower bound first and later
+ LIRC_SET_REC_DUTY_CYCLE/LIRC_SET_REC_CARRIER with the upper bound */
+
+-#define LIRC_SET_REC_DUTY_CYCLE_RANGE _IOW('i', 0x0000001e, __u32)
+-#define LIRC_SET_REC_CARRIER_RANGE _IOW('i', 0x0000001f, __u32)
++#define LIRC_SET_REC_DUTY_CYCLE_RANGE _IOW('i', 0x0000001e, u_int32_t)
++#define LIRC_SET_REC_CARRIER_RANGE _IOW('i', 0x0000001f, u_int32_t)
+
+ #endif
diff --git a/comms/lirc/files/patch-ab b/comms/lirc/files/patch-ab
new file mode 100644
index 000000000000..6ddcda7b022c
--- /dev/null
+++ b/comms/lirc/files/patch-ab
@@ -0,0 +1,40 @@
+--- daemons/Makefile.in.orig Sun Oct 6 05:24:53 2002
++++ daemons/Makefile.in Sat Jan 4 21:28:01 2003
+@@ -231,7 +231,7 @@
+ DEFAULT_INCLUDES = -I. -I$(srcdir) -I$(top_builddir)
+ CPPFLAGS = @CPPFLAGS@
+ LDFLAGS = @LDFLAGS@
+-LIBS = @LIBS@
++LIBS = @LIBS@ -L$(LOCALBASE)/lib -lgnugetopt
+ depcomp = $(SHELL) $(top_srcdir)/depcomp
+ @AMDEP_TRUE@DEP_FILES = $(DEPDIR)/config_file.Po \
+ @AMDEP_TRUE@ $(DEPDIR)/dump_config.Po $(DEPDIR)/hw-types.Po \
+@@ -265,7 +265,7 @@
+ CCLD = $(CC)
+ LINK = $(LIBTOOL) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+ $(AM_LDFLAGS) $(LDFLAGS) -o $@
+-CFLAGS = @CFLAGS@
++CFLAGS = @CFLAGS@ -I$(LOCALBASE)/include
+ DIST_SOURCES = $(irrecord_SOURCES) $(EXTRA_irrecord_SOURCES) \
+ $(lircd_SOURCES) $(EXTRA_lircd_SOURCES) $(lircd_simrec_SOURCES) \
+ $(lircd_simsend_SOURCES) $(lircmd_SOURCES) $(slinke_SOURCES)
+--- tools/Makefile.in.orig Sat Jan 4 22:02:21 2003
++++ tools/Makefile.in Sat Jan 4 22:03:09 2003
+@@ -192,7 +192,7 @@
+ DEFAULT_INCLUDES = -I. -I$(srcdir) -I$(top_builddir)
+ CPPFLAGS = @CPPFLAGS@
+ LDFLAGS = @LDFLAGS@
+-LIBS = @LIBS@
++LIBS = @LIBS@ -L$(LOCALBASE)/lib -lgnugetopt
+ depcomp = $(SHELL) $(top_srcdir)/depcomp
+ @AMDEP_TRUE@DEP_FILES = $(DEPDIR)/ircat.Po $(DEPDIR)/irexec.Po \
+ @AMDEP_TRUE@ $(DEPDIR)/irpty.Po $(DEPDIR)/irw.Po \
+@@ -206,7 +206,7 @@
+ CCLD = $(CC)
+ LINK = $(LIBTOOL) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+ $(AM_LDFLAGS) $(LDFLAGS) -o $@
+-CFLAGS = @CFLAGS@
++CFLAGS = @CFLAGS@ -I$(LOCALBASE)/include
+ DIST_SOURCES = $(liblirc_client_la_SOURCES) $(ircat_SOURCES) \
+ $(irexec_SOURCES) $(irpty_SOURCES) $(irw_SOURCES) \
+ $(irxevent_SOURCES) $(mode2_SOURCES) $(rc_SOURCES) \
diff --git a/comms/lirc/files/patch-ac b/comms/lirc/files/patch-ac
new file mode 100644
index 000000000000..98fcc2617926
--- /dev/null
+++ b/comms/lirc/files/patch-ac
@@ -0,0 +1,46 @@
+--- configure.orig Sun Oct 6 05:22:41 2002
++++ configure Sat Jan 4 21:23:16 2003
+@@ -9410,7 +9410,7 @@
+ echo "$as_me:9410: result: " >&5
+ echo "${ECHO_T}" >&6
+
+-possible_drivers="(none) (udp) (dsp) (remotemaster) (pctv) (logitech) \
++possible_drivers="(none) (dsp) (remotemaster) (pctv) (logitech) \
+ (slinke) (silitek) (mediafocusI) (irreal)"
+
+ if test x${no_kernel} != xyes; then
+@@ -9698,11 +9698,11 @@
+ esac
+ done
+ #remove duplicates
+- #hw_module=`echo ${hw_module}| tr ' ' '\n' | sort -u | tr '\n' ' '`
+- hw_module=`echo ${hw_module}| sed \
+- -e':again' \
+- -e's/\(.*\)\(\<.*\) \(.*\) \2\(.*\)$/\1\2 \3\4/' \
+- -e'tagain'`
++ hw_module=`echo ${hw_module}| tr ' ' '\n' | sort -u | tr '\n' ' '`
++ #hw_module=`echo ${hw_module}| sed \
++ # -e':again' \
++ # -e's/\(.*\)\(\<.*\) \(.*\) \2\(.*\)$/\1\2 \3\4/' \
++ # -e'tagain'`
+ fi
+
+ if test "$driver" = "irman"; then
+--- daemons/hw-types.c.orig Sat Jul 27 03:58:40 2002
++++ daemons/hw-types.c Sat Jan 4 21:13:11 2003
+@@ -15,7 +15,6 @@
+ extern struct hardware hw_silitek;
+ extern struct hardware hw_slinke;
+ extern struct hardware hw_dsp;
+-extern struct hardware hw_udp;
+
+ #ifndef HW_DEFAULT
+ # define HW_DEFAULT hw_default
+@@ -54,7 +53,6 @@
+ &hw_silitek,
+ &hw_slinke,
+ &hw_dsp,
+- &hw_udp,
+ &hw_null,
+ #else
+ &HW_DEFAULT,
diff --git a/comms/lirc/files/patch-ad b/comms/lirc/files/patch-ad
new file mode 100644
index 000000000000..c5716522ee21
--- /dev/null
+++ b/comms/lirc/files/patch-ad
@@ -0,0 +1,11 @@
+--- tools/irpty.c.orig Sat Jan 4 22:10:23 2003
++++ tools/irpty.c Sat Jan 4 22:11:26 2003
+@@ -36,7 +36,7 @@
+ #include <unistd.h>
+
+ #ifdef HAVE_FORKPTY
+-#include <pty.h>
++#include <libutil.h>
+ #endif
+
+ #include "lirc_client.h"
diff --git a/comms/lirc/pkg-descr b/comms/lirc/pkg-descr
new file mode 100644
index 000000000000..b9fe4c4639ee
--- /dev/null
+++ b/comms/lirc/pkg-descr
@@ -0,0 +1,22 @@
+LIRC is a package that allows you to decode and send infra-red signals
+of many (but not all) commonly used remote controls.
+
+The most important part of LIRC is the lircd daemon that will decode
+IR signals received by the device drivers and provide the information
+on a socket. It will also accept commands for IR signals to be sent if
+the hardware supports this. The second daemon program called lircmd
+will connect to lircd and translate the decoded IR signals to mouse
+movements. You can e.g. configure X to use your remote control as an
+input device.
+
+The user space applications will allow you to control your computer
+with your remote control. You can send X events to applications, start
+programs and much more on just one button press. The possible
+applications are obvious: Infra-red mouse, remote control for your TV
+tuner card or CD-ROM, shutdown by remote, program your VCR and/or
+satellite tuner with your computer, etc.
+
+WWW: http://www.lirc.org/
+
+- Mike
+mikeh@FreeBSD.org
diff --git a/comms/lirc/pkg-message b/comms/lirc/pkg-message
new file mode 100644
index 000000000000..f99cb6a78901
--- /dev/null
+++ b/comms/lirc/pkg-message
@@ -0,0 +1,8 @@
+**********************************************************************
+This port does not contain any FreeBSD device drivers for infrared
+devices. This port installs the LIRC daemons and tools for interacting
+with drivers that support the LIRC device interface.
+
+You will need to obtain third party device drivers or port the Linux
+drivers in ${WRKSRC}/drivers to use the LIRC port.
+**********************************************************************
diff --git a/comms/lirc/pkg-plist b/comms/lirc/pkg-plist
new file mode 100644
index 000000000000..ad0ce7d772bf
--- /dev/null
+++ b/comms/lirc/pkg-plist
@@ -0,0 +1,17 @@
+bin/ircat
+bin/irexec
+bin/irpty
+bin/irrecord
+bin/irw
+bin/irxevent
+bin/mode2
+bin/rc
+bin/xmode2
+include/lirc/lirc_client.h
+@dirrm include/lirc
+lib/liblirc_client.a
+lib/liblirc_client.la
+lib/liblirc_client.so
+lib/liblirc_client.so.0
+sbin/lircd
+sbin/lircmd