Compare commits

...
Sign in to create a new pull request.

5 commits

Author SHA1 Message Date
Fedora Release Engineering
627749ef2e dist-git conversion 2010-07-28 20:34:05 +00:00
Bill Nottingham
a2340bd8f7 Fix typo that causes a failure to update the common directory. (releng
#2781)
2009-11-26 01:44:50 +00:00
Nicolas Chauvet
d0f0bc59e4 - Improve the initscripts patch - Fix #498384 2009-05-13 16:38:59 +00:00
Nicolas Chauvet
465882913f Backport some fixes 2009-04-26 09:11:48 +00:00
Jesse Keating
4f4bccc0cd Initialize branch F-9 for lcdproc 2008-04-21 01:27:28 +00:00
7 changed files with 3266 additions and 130 deletions

View file

View file

@ -1,21 +0,0 @@
# Makefile for source rpm: lcdproc
# $Id$
NAME := lcdproc
SPECFILE = $(firstword $(wildcard *.spec))
define find-makefile-common
for d in common ../common ../../common ; do if [ -f $$d/Makefile.common ] ; then if [ -f $$d/CVS/Root -a -w $$/Makefile.common ] ; then cd $$d ; cvs -Q update ; fi ; echo "$$d/Makefile.common" ; break ; fi ; done
endef
MAKEFILE_COMMON := $(shell $(find-makefile-common))
ifeq ($(MAKEFILE_COMMON),)
# attept a checkout
define checkout-makefile-common
test -f CVS/Root && { cvs -Q -d $$(cat CVS/Root) checkout common && echo "common/Makefile.common" ; } || { echo "ERROR: I can't figure out how to checkout the 'common' module." ; exit -1 ; } >&2
endef
MAKEFILE_COMMON := $(shell $(checkout-makefile-common))
endif
include $(MAKEFILE_COMMON)

2859
lcdproc-0.5.2-imonlcd.patch Normal file

File diff suppressed because it is too large Load diff

View file

@ -0,0 +1,310 @@
diff -up lcdproc-0.5.2/scripts/init-LCDd.LSB.in.initscripts lcdproc-0.5.2/scripts/init-LCDd.LSB.in
--- lcdproc-0.5.2/scripts/init-LCDd.LSB.in.initscripts 2007-04-14 16:41:20.000000000 +0200
+++ lcdproc-0.5.2/scripts/init-LCDd.LSB.in 2009-05-13 17:14:25.000000000 +0200
@@ -1,10 +1,18 @@
#! /bin/sh
+#
+# chkconfig: - 70 21
+# description: LCDd(8) is the LCDproc server used for displaying text and other data to LCDs. \
+# Apart from the main client lcdproc(1) there are various clients. \
+# See http://lcdproc.omnipotent.net for details.
+# processname: LCDd
+#
+# config: /etc/sysconfig/lcdproc/LCDd.conf
-#### BEGIN INIT INFO
+### BEGIN INIT INFO
# Provides: LCDd
# Required-Start: $syslog $local_fs $network $remote_fs
# Required-Stop: $syslog $local_fs $network $remote_fs
-# Default-Start: 2 3 4 5
+# Default-Start:
# Default-Stop: S 0 1 6
# Short-Description: LCDproc Server Daemon
# Description: LSB init script for LCDd, the display
@@ -12,57 +20,92 @@
### END INIT INFO
-# local variables
-prefix=@prefix@
-exec_prefix=@exec_prefix@
-bindir=@bindir@
-sbindir=@sbindir@
-etc=@sysconfdir@
-
-PATH=/sbin:/bin:/usr/sbin:/usr/bin
-NAME=LCDd
-DAEMON=${sbindir}/$NAME
-DESC="LCDproc display server daemon"
-DEFAULTS=/etc/default/$NAME
-START=yes
-
-# Source defaults file; edit that file to configure this script.
-if [ -e "${DEFAULTS}" ]; then
- . "${DEFAULTS}"
+prog=LCDd
+lockfile=/var/lock/subsys/$prog
+configfile=@sysconfdir@/$prog.conf
+RETVAL=0
+
+
+# load LSB 3.x init functions
+if [ -e /lib/lsb/init-functions ]; then
+ . /lib/lsb/init-functions
fi
-# If we're not to start the daemon, simply exit
-if [ "${START}" != "yes" ]; then
- exit 0
+# Source function library.
+if [ -e /etc/rc.d/init.d/functions ]; then
+ . /etc/rc.d/init.d/functions
fi
-# installation check
-test -x $DAEMON || exit 5
+# check that non-default config file exists.
+ [ -f $configfile ] || exit 6
-# load LSB 3.x init functions
-. /lib/lsb/init-functions
+
+start() {
+ echo -n $"Starting $prog services: "
+ daemon $prog -c $configfile
+ RETVAL=$?
+ echo
+ [ $RETVAL -eq 0 ] && touch $lockfile || \
+ RETVAL=1
+ return $RETVAL
+}
+
+stop() {
+ echo -n $"Shutting down $prog services: "
+ killproc $prog
+ RETVAL=$?
+ echo
+ [ $RETVAL -eq 0 ] && rm -f $lockfile
+ return $RETVAL
+}
+
+reload() {
+ echo -n $"Reloading $prog file: "
+ killproc $prog -HUP
+ RETVAL=$?
+ echo
+ return $RETVAL
+}
+
+rhstatus() {
+ status $prog
+ return $?
+}
+
+
+# Allow status as non-root.
+if [ "$1" = status ]; then
+ rhstatus
+ exit $?
+fi
case "$1" in
start)
- log_daemon_msg "Starting $DESC" "$NAME"
- start_daemon $DAEMON $OPTIONS
- log_end_msg $?
+ start
;;
stop)
- log_daemon_msg "Stopping $DESC" "$NAME"
- killproc $DAEMON
- log_end_msg $?
- ;;
- restart|reload|force-reload)
- $0 stop
- sleep 1
- $0 start
+ stop
+ ;;
+ status)
+ status $prog
+ ;;
+ restart|force-reload)
+ stop
+ start
+ ;;
+ try-restart|condrestart)
+ if [ -f $lockfile ]; then
+ stop
+ start
+ fi
+ ;;
+ reload)
+ reload
;;
*)
- echo "Usage: $0 {start|stop|restart|reload|force-reload}" >&2
+ echo $"Usage: $0 {start|stop|status|restart|try-restart|force-reload}"
exit 2
- ;;
esac
-exit 0
+exit $RETVAL
diff -up lcdproc-0.5.2/scripts/init-lcdproc.LSB.in.initscripts lcdproc-0.5.2/scripts/init-lcdproc.LSB.in
--- lcdproc-0.5.2/scripts/init-lcdproc.LSB.in.initscripts 2007-04-14 16:41:20.000000000 +0200
+++ lcdproc-0.5.2/scripts/init-lcdproc.LSB.in 2009-05-13 10:37:32.000000000 +0200
@@ -1,10 +1,19 @@
#! /bin/sh
+#
+# chkconfig: - 71 20
+# description: LCDd(8) is the LCDproc server used for displaying text and other data to LCDs. \
+# Apart from the main client lcdproc(1) there are various clients. \
+# See http://lcdproc.omnipotent.net for details.
+# processname: lcdproc
+#
+# config: /etc/sysconfig/lcdproc/lcdproc.conf
-#### BEGIN INIT INFO
+### BEGIN INIT INFO
# Provides: lcdproc
# Required-Start: $syslog $local_fs $network $remote_fs
# Required-Stop: $syslog $local_fs $network $remote_fs
-# Default-Start: 2 3 4 5
+# Should-Start: LCDd
+# Default-Start:
# Default-Stop: S 0 1 6
# Short-Description: LCDproc system status information viewer
# Description: LSB init script for lcdproc, the system
@@ -12,57 +21,91 @@
### END INIT INFO
-# local variables
-prefix=@prefix@
-exec_prefix=@exec_prefix@
-bindir=@bindir@
-sbindir=@sbindir@
-etc=@sysconfdir@
-
-PATH=/sbin:/bin:/usr/sbin:/usr/bin
-NAME=lcdproc
-DAEMON=${bindir}/$NAME
-DESC="LCDproc system status monitor"
-DEFAULTS=/etc/default/$NAME
-START=yes
-
-# Source defaults file; edit that file to configure this script.
-if [ -e "${DEFAULTS}" ]; then
- . "${DEFAULTS}"
+prog=lcdproc
+lockfile=/var/lock/subsys/$prog
+configfile=@sysconfdir@/$prog.conf
+RETVAL=0
+
+# load LSB 3.x init functions
+if [ -e /lib/lsb/init-functions ]; then
+ . /lib/lsb/init-functions
fi
-# If we're not to start the daemon, simply exit
-if [ "${START}" != "yes" ]; then
- exit 0
+# Source function library.
+if [ -e /etc/rc.d/init.d/functions ]; then
+ . /etc/rc.d/init.d/functions
fi
-# installation check
-test -x $DAEMON || exit 5
+# check that non-default config file exists.
+ [ -f $configfile ] || exit 6
-# load LSB 3.x init functions
-. /lib/lsb/init-functions
+
+start() {
+ echo -n $"Starting $prog services: "
+ daemon $prog -c $configfile
+ RETVAL=$?
+ echo
+ [ $RETVAL -eq 0 ] && touch $lockfile || \
+ RETVAL=1
+ return $RETVAL
+}
+
+stop() {
+ echo -n $"Shutting down $prog services: "
+ killproc $prog
+ RETVAL=$?
+ echo
+ [ $RETVAL -eq 0 ] && rm -f $lockfile
+ return $RETVAL
+}
+
+reload() {
+ echo -n $"Reloading $prog file: "
+ killproc $prog -HUP
+ RETVAL=$?
+ echo
+ return $RETVAL
+}
+
+rhstatus() {
+ status $prog
+ return $?
+}
+
+
+# Allow status as non-root.
+if [ "$1" = status ]; then
+ rhstatus
+ exit $?
+fi
case "$1" in
start)
- log_daemon_msg "Starting $DESC" "$NAME"
- start_daemon $DAEMON $OPTIONS
- log_end_msg $?
+ start
;;
stop)
- log_daemon_msg "Stopping $DESC" "$NAME"
- killproc $DAEMON
- log_end_msg $?
- ;;
- restart|reload|force-reload)
- $0 stop
- sleep 1
- $0 start
+ stop
+ ;;
+ status)
+ status $prog
+ ;;
+ restart|force-reload)
+ stop
+ start
+ ;;
+ try-restart|condrestart)
+ if [ -f $lockfile ]; then
+ stop
+ start
+ fi
+ ;;
+ reload)
+ reload
;;
*)
- echo "Usage: $0 {start|stop|restart|reload|force-reload}" >&2
+ echo $"Usage: $0 {start|stop|status|restart|try-restart|force-reload}"
exit 2
- ;;
esac
-exit 0
+exit $RETVAL

View file

@ -0,0 +1,22 @@
diff -up lcdproc-0.5.2/docs/lcdproc-dev/Makefile.am.novalidate lcdproc-0.5.2/docs/lcdproc-dev/Makefile.am
--- lcdproc-0.5.2/docs/lcdproc-dev/Makefile.am.novalidate 2007-04-14 16:39:53.000000000 +0200
+++ lcdproc-0.5.2/docs/lcdproc-dev/Makefile.am 2009-04-14 15:28:01.000000000 +0200
@@ -18,6 +18,6 @@ developerguidedir = $(DESTDIR)$(htmldir)
install-html-developerguide: $(xmlto) lcdproc-dev.docbook
$(mkinstalldirs) $(developerguidedir)
- $(xmlto) html -o $(developerguidedir) lcdproc-dev.docbook
+ $(xmlto) html -o $(developerguidedir) --skip-validation lcdproc-dev.docbook
## EOF
diff -up lcdproc-0.5.2/docs/lcdproc-user/Makefile.am.novalidate lcdproc-0.5.2/docs/lcdproc-user/Makefile.am
--- lcdproc-0.5.2/docs/lcdproc-user/Makefile.am.novalidate 2009-04-14 15:32:24.000000000 +0200
+++ lcdproc-0.5.2/docs/lcdproc-user/Makefile.am 2009-04-14 15:32:44.000000000 +0200
@@ -21,6 +21,6 @@ userguidedir = $(DESTDIR)$(htmldir)/user
install-html-userguide: $(xmlto) lcdproc-user.docbook
$(mkinstalldirs) $(userguidedir)
- $(xmlto) html -o $(userguidedir) lcdproc-user.docbook
+ $(xmlto) html -o $(userguidedir) --skip-validation lcdproc-user.docbook
## EOF

View file

@ -1,86 +0,0 @@
--- lcdproc-0.5.2/scripts/init-LCDd.rpm.in.initscripts 2007-05-20 14:17:36.000000000 +0200
+++ lcdproc-0.5.2/scripts/init-LCDd.rpm.in 2007-05-20 14:22:24.000000000 +0200
@@ -19,7 +19,7 @@
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301
#
#
-# chkconfig: 345 70 21
+# chkconfig: - 70 21
# description: LCDd(8) is the LCDproc server used for displaying text and other data to LCDs. \
# Apart from the main client lcdproc(1) there are various clients. \
# See http://lcdproc.omnipotent.net for details.
@@ -73,6 +73,12 @@
RETVAL=$?
}
+reload() {
+ stop
+ start
+ RETVAL=$?
+}
+
restart() {
stop
start
@@ -94,6 +100,9 @@
status)
dostatus
;;
+ reload)
+ restart
+ ;;
restart)
restart
;;
@@ -101,7 +110,7 @@
condrestart
;;
*)
- echo "Usage: $0 {start|stop|status|restart|condrestart}"
+ echo "Usage: $0 {start|stop|status|reload|restart|condrestart}"
exit 1
esac
--- lcdproc-0.5.2/scripts/init-lcdproc.rpm.in.initscripts 2007-05-20 14:17:02.000000000 +0200
+++ lcdproc-0.5.2/scripts/init-lcdproc.rpm.in 2007-05-20 14:21:13.000000000 +0200
@@ -19,7 +19,7 @@
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301
#
#
-# chkconfig: 345 71 20
+# chkconfig: - 71 20
# description: LCDd(8) is the LCDproc server used for displaying text and other data to LCDs. \
# Apart from the main client lcdproc(1) there are various clients. \
# See http://lcdproc.omnipotent.net for details.
@@ -73,6 +73,12 @@
RETVAL=$?
}
+reload() {
+ stop
+ start
+ RETVAL=$?
+}
+
restart() {
stop
start
@@ -94,6 +100,9 @@
status)
dostatus
;;
+ reload)
+ restart
+ ;;
restart)
restart
;;
@@ -101,7 +110,7 @@
condrestart
;;
*)
- echo "Usage: $0 {start|stop|status|restart|condrestart}"
+ echo "Usage: $0 {start|stop|status|reload|restart|condrestart}"
exit 1
esac

View file

@ -1,19 +1,23 @@
Summary: LCDproc displays real-time system information on a 20x4 backlit LCD
Name: lcdproc
Name: lcdproc
Version: 0.5.2
Release: 4%{?dist}
Release: 12%{?dist}
License: GPLv2
URL: http://lcdproc.omnipotent.net
Group: System Environment/Libraries
Group: System Environment/Libraries
Source0: http://downloads.sourceforge.net/%{name}/%{name}-%{version}.tar.gz
Patch0: lcdproc-0.5.2-scripts.patch
Patch0: lcdproc-0.5.2-initscripts.patch
Patch1: lcdproc-0.5.2-memset_swp.patch
Patch2: lcdproc-0.5.2-imonlcd.patch
Patch3: lcdproc-0.5.2-novalidate.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildRequires: doxygen
BuildRequires: graphviz
BuildRequires: glibc-headers
# necessary for imonlcd patch
BuildRequires: libtool
BuildRequires: libusb-devel
BuildRequires: lirc-devel
BuildRequires: ncurses-devel
@ -21,6 +25,9 @@ BuildRequires: nfs-utils-lib-devel
BuildRequires: openldap-devel
BuildRequires: pth-devel
BuildRequires: xmlto
%if 0%{?fedora} > 9
BuildRequires: docbook-dtds
%endif
BuildRequires: xosd-devel
BuildRequires: libX11-devel
BuildRequires: libXext-devel
@ -37,22 +44,30 @@ Requires(postun): /sbin/chkconfig
%description
LCDproc is a client/server suite inclduding drivers for all
kinds of nifty LCD displays. The server supports several
serial devices: Matrix Orbital, Crystal Fontz, Bayrad, LB216,
LCDM001 (kernelconcepts.de), Wirz-SLI and PIC-an-LCD; and some
devices connected to the LPT port: HD44780, STV5730, T6963,
SED1520 and SED1330. Various clients are available that display
things like CPU load, system load, memory usage, uptime, and a lot more.
See also http://lcdproc.omnipotent.net.
serial devices: Matrix Orbital, Crystal Fontz, Bayrad, LB216,
LCDM001 (kernelconcepts.de), Wirz-SLI and PIC-an-LCD; and some
devices connected to the LPT port: HD44780, STV5730, T6963,
SED1520 and SED1330. Various clients are available that display
things like CPU load, system load, memory usage, uptime, and a lot more.
See also http://lcdproc.omnipotent.net.
%prep
%setup -q
%patch0 -p1 -b .initscripts
%patch1 -p1 -b .memset_swp
%patch2 -p1 -b .imonlcd
%patch3 -p1 -b .novalidate
chmod 644 server/drivers/timing.h
sed -i -e 's|server/drivers|%{_libdir}/lcdproc|' LCDd.conf
touch -r TODO LCDd.conf
%build
# run autoreconf to pick up the imon lcd additions
# liboolize to refresh libtool
autoreconf -f -i
libtoolize --force
%configure \
--sysconfdir=%{_sysconfdir}/sysconfig/%{name} \
--enable-libusb \
@ -64,34 +79,41 @@ chmod 644 server/drivers/timing.h
--enable-stat-smbfs \
--with-lcdport=13666
sed -i -e 's|-L/usr/lib|-L%{_libdir}|g' Makefile
make CFLAGS="$RPM_OPT_FLAGS" %{?_smp_mflags}
make %{?_smp_mflags}
%install
rm -rf $RPM_BUILD_ROOT __doc
make install DESTDIR=$RPM_BUILD_ROOT
make install-html-guides DESTDIR=$RPM_BUILD_ROOT
make install DESTDIR=$RPM_BUILD_ROOT INSTALL="install -p"
make install-html-guides DESTDIR=$RPM_BUILD_ROOT INSTALL="install -p"
# Fix docs
mkdir -p __doc/developer-guide
mkdir -p __doc/user-guide
install -m 0644 $RPM_BUILD_ROOT%{_datadir}/doc/lcdproc/user-guide/* __doc/user-guide
install -m 0644 $RPM_BUILD_ROOT%{_datadir}/doc/lcdproc/developer-guide/* __doc/developer-guide
install -pm 0644 $RPM_BUILD_ROOT%{_datadir}/doc/lcdproc/user-guide/* __doc/user-guide
install -pm 0644 $RPM_BUILD_ROOT%{_datadir}/doc/lcdproc/developer-guide/* __doc/developer-guide
rm -rf $RPM_BUILD_ROOT%{_datadir}/doc
# init
install -d $RPM_BUILD_ROOT%{_initrddir}
install -pm 0755 scripts/init-LCDd.rpm $RPM_BUILD_ROOT%{_initrddir}/LCDd
install -pm 0755 scripts/init-lcdproc.rpm $RPM_BUILD_ROOT%{_initrddir}/lcdproc
install -pm 0755 scripts/init-LCDd.LSB $RPM_BUILD_ROOT%{_initrddir}/LCDd
install -pm 0755 scripts/init-lcdproc.LSB $RPM_BUILD_ROOT%{_initrddir}/lcdproc
#Disable default configuration
#Thoses are only provided as an example since ncurses isn't a suitable default configuration.
for f in LCDd.conf lcdproc.conf ; do
mv $RPM_BUILD_ROOT%{_sysconfdir}/sysconfig/%{name}/${f} \
$RPM_BUILD_ROOT%{_sysconfdir}/sysconfig/%{name}/${f}.example
touch $RPM_BUILD_ROOT%{_sysconfdir}/sysconfig/%{name}/${f}
done
%post
if [ $1 -eq 1 ]; then
# Add init script but don't start it
/sbin/chkconfig --add LCDd
/sbin/chkconfig --add LCDd
/sbin/chkconfig --add lcdproc ||:
fi
@ -119,12 +141,42 @@ rm -rf $RPM_BUILD_ROOT __doc
%{_sbindir}/*
%{_mandir}/man?/*
%dir %{_sysconfdir}/sysconfig/%{name}
%config(noreplace) %{_sysconfdir}/sysconfig/%{name}/*.conf
%ghost %{_sysconfdir}/sysconfig/%{name}/*.conf
%config %{_sysconfdir}/sysconfig/%{name}/*.conf.example
%{_initrddir}/LCDd
%{_initrddir}/lcdproc
%changelog
* Wed May 13 2009 kwizart < kwizart at gmail.com > - 0.5.2-12
- Improve the initscripts patch - Fix #498384
* Tue Apr 14 2009 kwizart < kwizart at gmail.com > - 0.5.2-11
- Disable xmlto validation (Fix FTBFS)
- Disable default configuration (only provided as examples)
* Thu Mar 5 2009 kwizart < kwizart at gmail.com > - 0.5.2-10
- Disable LCDd lcdproc initscript by default.
(It needs to be configured first).
* Mon Mar 2 2009 kwizart < kwizart at gmail.com > - 0.5.2-9
- re-enable patch0
- Prevent some timestamps changes.
* Wed Feb 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.5.2-8
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
* Fri Nov 07 2008 Jarod Wilson <jarod@redhat.com> - 0.5.2-7
- Add SoundGraph iMon and Antec Veris LCD device support
- Replace start_daemon w/daemon in initscripts (#468611)
* Tue Jul 8 2008 kwizart < kwizart at gmail.com > - 0.5.2-6
- Add BR on Fedora > 9 : docbook-dtds
* Tue Jul 8 2008 kwizart < kwizart at gmail.com > - 0.5.2-5
- Fix RETVAL for LSB compliant initscripts - #246971
- Fix Default driver path - #454194
* Sat Feb 9 2008 kwizart < kwizart at gmail.com > - 0.5.2-4
- Rebuild for gcc43
@ -134,7 +186,7 @@ rm -rf $RPM_BUILD_ROOT __doc
* Sun Aug 12 2007 kwizart < kwizart at gmail.com > 0.5.2-2
- Fix memset swap from djones advice
- License is GPLv2
- Fix #246971
- Fix #246971
* Sat May 19 2007 kwizart < kwizart at gmail.com > 0.5.2-1
- Update to 0.5.2