From 3b7cb6d53c643acc877af72be304cec541c379f2 Mon Sep 17 00:00:00 2001 From: cvsextras Date: Mon, 8 Nov 2004 04:49:37 +0000 Subject: [PATCH] auto-import changelog data from lirc-0.6.6-3.1.fc2.fr.src.rpm //freshrpms.net/> 0.6.6-3 - Added missing /sbin/ldconfig calls. //freshrpms.net/> 0.6.6-2 - Rebuild for Fedora Core 2... this spec file still _really_ needs reworking! //freshrpms.net/> 0.6.6-2 - Rebuild for Fedora Core 1... this spec file _really_ needs reworking! //freshrpms.net/> - Rebuilt for Red Hat Linux 9... this spec file needs some reworking! //freshrpms.net/> - Update to 0.6.6 final. //freshrpms.net/> - Updated to latest pre-version. - Kernel modules still need to be compiled separately and with a custom kernel :-( //freshrpms.net/> - Update to 0.6.5. - Rebuilt against Red Hat Linux 7.3. - Added the %{?_smp_mflags} expansion. //freshrpms.net/> - Initial RPM release. --- .cvsignore | 1 + lirc.spec | 144 ++++++++++++++++++++++++++++++++++++++++++++++++ lircd.init | 81 +++++++++++++++++++++++++++ lircd.logrotate | 8 +++ sources | 1 + 5 files changed, 235 insertions(+) create mode 100644 lirc.spec create mode 100755 lircd.init create mode 100644 lircd.logrotate diff --git a/.cvsignore b/.cvsignore index e69de29..08b1a75 100644 --- a/.cvsignore +++ b/.cvsignore @@ -0,0 +1 @@ +lirc-0.6.6.tar.bz2 diff --git a/lirc.spec b/lirc.spec new file mode 100644 index 0000000..049afb4 --- /dev/null +++ b/lirc.spec @@ -0,0 +1,144 @@ +# $Id: lirc.spec 2135 2004-08-30 13:51:15Z dude $ +# Authority: matthias + +# The driver(s) you want to compile in, e.g. "pctv", "serial", "any" +%define driver "pctv" + +# Are we compiling drivers that will need a kernel module too +# (you'll still need to recompile an entire kernel, keep the sources, then +# recompile lirc to get the modules...) +%define kmodule 0 + +#%%if %{kmodule} +#%%define kunamer %%(uname -r) +#%%define kver %%(echo $(uname -r) | sed -e s/smp// -) +#%%define karch %%(rpm -q --qf '%%%{arch}' kernel-%%{kversion}) +#%%define krelver %%(echo %%{kunamer} | tr -s '-' '_') +#%%endif + +Summary: The Linux Infrared Remote Control package +Name: lirc +Version: 0.6.6 +#%%if %{kmodule} +#Release: fr1_%{krelver} +#%%else +Release: 3.1.fc2.fr +#%%endif +License: GPL +Group: System Environment/Daemons +URL: http://www.lirc.org/ +Source0: http://dl.sf.net/lirc/%{name}-%{version}.tar.bz2 +Source1: lircd.init +Source2: lircd.logrotate +BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root +PreReq: /sbin/chkconfig, /sbin/service +BuildRequires: perl +#%%if %{kmodule} +#Requires: kernel = %{kver} +#BuildRequires: kernel-source = %{kver} +#%%endif + +%description +LIRC is the Linux Infrared Remote Control package. +This package features a clean lircd initscript and a logrotate config file. + +The default binary build of this package will only work with the Pinnacle +PCTV serial remote, if you have a different device, you will probably need +to recompile the source RPM changing the "--with-driver=" configure option +to your device. + +If your remote requires special kernel modules to run, I guess you're stuck +having to recompile a kernel and recompile lirc manually to get the modules! + + +%prep +%setup + + +%build +%configure \ + --with-driver=%{driver} \ + --disable-manage-devices +%{__make} %{?_smp_mflags} + + +%install +%{__rm} -rf %{buildroot} +%{__make} install DESTDIR=%{buildroot} +%{__install} -m 755 -D %{SOURCE1} %{buildroot}/etc/init.d/lircd +%{__install} -m 644 -D %{SOURCE2} %{buildroot}/etc/logrotate.d/lircd +%{__perl} -pi -e 's|\@SBINDIR\@|%{_sbindir}|g' %{buildroot}/etc/init.d/lircd +%{__rm} -f doc/Makefile* +%{__mkdir_p} %{buildroot}/dev +%{__ln_s} -f ttyS0 %{buildroot}/dev/lirc +touch %{buildroot}/etc/lircd.conf +touch %{buildroot}/etc/lircmd.conf + +%post +/sbin/ldconfig +/sbin/chkconfig --add lircd + +%preun +if [ $1 = 0 ]; then + /sbin/service lircd stop > /dev/null 2>&1 || : + /sbin/chkconfig --del lircd +fi + +%postun +/sbin/ldconfig +if [ "$1" -ge "1" ]; then + /sbin/service lircd condrestart >/dev/null 2>&1 || : +fi + +%clean +%{__rm} -rf %{buildroot} + +%files +%defattr(-, root, root, 0755) +%doc ANNOUNCE AUTHORS ChangeLog COPYING NEWS README TODO doc remotes +%doc contrib/*.conf contrib/irman2lirc contrib/lircrc contrib/lircs +/etc/init.d/lircd +/etc/logrotate.d/lircd +%ghost %config(noreplace) /etc/lircd.conf +%ghost %config(noreplace) /etc/lircmd.conf +%{_bindir}/* +%{_sbindir}/* +%{_includedir}/lirc +%{_libdir}/liblirc_* +%{_mandir}/man?/* +%if %{kmodule} +#/lib/modules/%{kver}/misc/* +%attr(0644, root, root) %dev(c, 61, 0) /dev/lirc +%else +/dev/lirc +%endif + +%changelog +* Mon Aug 30 2004 Matthias Saou 0.6.6-3 +- Added missing /sbin/ldconfig calls. + +* Wed May 19 2004 Matthias Saou 0.6.6-2 +- Rebuild for Fedora Core 2... this spec file still _really_ needs reworking! + +* Fri Nov 7 2003 Matthias Saou 0.6.6-2 +- Rebuild for Fedora Core 1... this spec file _really_ needs reworking! + +* Mon Mar 31 2003 Matthias Saou +- Rebuilt for Red Hat Linux 9... this spec file needs some reworking! + +* Mon Oct 7 2002 Matthias Saou +- Update to 0.6.6 final. + +* Mon Sep 16 2002 Matthias Saou +- Updated to latest pre-version. +- Kernel modules still need to be compiled separately and with a custom + kernel :-( + +* Thu May 2 2002 Matthias Saou +- Update to 0.6.5. +- Rebuilt against Red Hat Linux 7.3. +- Added the %%{?_smp_mflags} expansion. + +* Thu Oct 4 2001 Matthias Saou +- Initial RPM release. + diff --git a/lircd.init b/lircd.init new file mode 100755 index 0000000..f3aa6ac --- /dev/null +++ b/lircd.init @@ -0,0 +1,81 @@ +#!/bin/sh +# +# $Id: lircd.init,v 1.1 2004/02/26 17:54:30 thias Exp $ +# Startup script for the Linux Infrared Remote Control. +# +# chkconfig: - 90 10 +# description: Enables infrared controls through LIRC. +# +# config: /etc/lircd.conf + +# Source 'em up +. /etc/init.d/functions + +[ -x @SBINDIR@/lircd ] || exit 1 +[ -x @SBINDIR@/lircmd ] || exit 1 +[ -f /etc/lircd.conf ] || [ -f /etc/lircmd.conf ] || exit 1 + +RETVAL=0 + +start(){ + if [ -f /etc/lircd.conf ]; then + echo -n $"Starting infrared remote control daemon: " + daemon lircd + RETVAL=$? + echo + fi + if [ -f /etc/lircmd.conf ]; then + echo -n $"Starting infrared remote control mouse daemon: " + daemon lircmd + RETVAL=$? + echo + fi + touch /var/lock/subsys/lircd + return $RETVAL +} + +stop(){ + if [ -f /etc/lircmd.conf ]; then + echo -n $"Stopping infrared remote control mouse daemon: " + killproc lircmd + echo + fi + if [ -f /etc/lircd.conf ]; then + echo -n $"Stopping infrared remote control daemon: " + killproc lircd + echo + fi + RETVAL=$? + rm -f /var/lock/subsys/lircd + return $RETVAL +} + +restart(){ + stop + start +} + + +# See how we were called. +case "$1" in + start) + start + ;; + stop) + stop + ;; + restart) + restart + ;; + status) + status lircd + ;; + condrestart) + [ -e /var/lock/subsys/lircd ] && restart + ;; + *) + echo $"Usage: $0 {start|stop|status|restart|condrestart}" + RETVAL=1 +esac + +exit $RETVAL diff --git a/lircd.logrotate b/lircd.logrotate new file mode 100644 index 0000000..05ade79 --- /dev/null +++ b/lircd.logrotate @@ -0,0 +1,8 @@ +# $Id: lircd.logrotate,v 1.1 2004/11/08 04:49:37 cvsextras Exp $ + +/var/log/lircd { + missingok + postrotate + [ -e /var/lock/subsys/lircd ] && /bin/kill -HUP `/bin/cat /var/run/lircd.pid` || /bin/true + endscript +} diff --git a/sources b/sources index e69de29..4ce285c 100644 --- a/sources +++ b/sources @@ -0,0 +1 @@ +6e7b5ba2fd479961d067730e16df7c54 lirc-0.6.6.tar.bz2