packages: uptimed/uptimed.spec - up to 0.3.17 - added uptimed.init for rc.s...
blekot
blekot at pld-linux.org
Wed May 16 17:22:11 CEST 2012
Author: blekot Date: Wed May 16 15:22:11 2012 GMT
Module: packages Tag: HEAD
---- Log message:
- up to 0.3.17
- added uptimed.init for rc.scripts
- added /sbin/ldconfig to post{,un}
- remove bundled getopt
- disable-static in configure
- added temporary fix against unresolved symbol u_current
- need review
---- Files affected:
packages/uptimed:
uptimed.spec (1.30 -> 1.31)
---- Diffs:
================================================================
Index: packages/uptimed/uptimed.spec
diff -u packages/uptimed/uptimed.spec:1.30 packages/uptimed/uptimed.spec:1.31
--- packages/uptimed/uptimed.spec:1.30 Sat Jan 29 01:07:31 2011
+++ packages/uptimed/uptimed.spec Wed May 16 17:22:06 2012
@@ -1,26 +1,29 @@
# $Revision$, $Date$
#
# TODO:
-# - find other way to start than messing with rc.sysinit and rc.local
-# new one uses rc.script
# - add CGI stuff
#
Summary: Uptime record daemon - keeps track of the highest system uptimes
Summary(pl.UTF-8): Demon śledzący największe uptime serwera
Name: uptimed
-Version: 0.3.16
-Release: 0.1
+Version: 0.3.17
+Release: 0.5
License: GPL v2+
Group: Applications/System
Source0: http://podgorny.cz/uptimed/releases/%{name}-%{version}.tar.bz2
-# Source0-md5: f87ec2cc39039239004afa542cf99c59
+# Source0-md5: d342918ea3a5117c127c67c9d3ed74e6
+Source1: %{name}.init
URL: http://podgorny.cz/moin/Uptimed
BuildRequires: autoconf
BuildRequires: automake
BuildRequires: libtool
Requires(post): grep
+Requires(post,postun): /sbin/ldconfig
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
+# Temporary fix. unresolved symbol u_current
+%define skip_post_check_so libuptimed\.so\.0\.0\.0
+
%description
Uptimed is an uptime record daemon keeping track of the highest
uptimes the system ever had. Instead of using a pid-file to keep
@@ -37,15 +40,20 @@
%prep
%setup -q
+# remove bundled getopt
+# it should be probably added as patch
+%{__rm} -rf src/getopt.[ch]
+%{__sed} --in-place -e 's/AC_REPLACE_FUNCS(getopt)//' configure.ac
%build
%{__libtoolize}
%{__aclocal}
%{__autoconf}
%{__automake}
-%configure
+%configure \
+ --disable-static
-%{__make}
+%{__make}
%install
rm -rf $RPM_BUILD_ROOT
@@ -53,39 +61,33 @@
%{__make} install \
DESTDIR=$RPM_BUILD_ROOT
+# We don't need libuptimed.la libuptimed.so
+rm -f $RPM_BUILD_ROOT%{_libdir}/libuptimed.la
+rm -f $RPM_BUILD_ROOT%{_libdir}/libuptimed.so
%{__mv} $RPM_BUILD_ROOT%{_sysconfdir}/uptimed.conf{-dist,}
+# Create dir for init.d
+install -d $RPM_BUILD_ROOT/etc/rc.d/init.d
+install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/%{name}
+
%clean
rm -rf $RPM_BUILD_ROOT
%post
-if ! grep -q uptimed /etc/rc.d/rc.local ; then
- echo "echo \"Starting uptime daemon...\"" >> /etc/rc.d/rc.local
- echo "/usr/sbin/uptimed" >> /etc/rc.d/rc.local
-fi
-if ! grep -q uptimed /etc/rc.d/rc.sysinit ; then
- echo "echo \"Creating unique uptime daemon bootid...\"" >> /etc/rc.d/rc.sysinit
- echo "/usr/sbin/uptimed -b" >> /etc/rc.d/rc.sysinit
-fi
+/sbin/ldconfig
%postun
-echo "Please edit /etc/rc.d/rc.local and /etc/rc.d/rc.sysinit and take out the following lines"
-echo "They should be at the very bottom of the file.."
-echo ""
-echo "-- /etc/rc.d/rc.local --"
-echo "echo \"Starting uptime daemon...\""
-echo "/usr/sbin/uptimed"
-echo "-- /etc/rc.d/rc.sysinit --"
-echo "echo \"Creating unique uptime daemon bootid...\""
-echo "/usr/sbin/uptimed -b"
+/sbin/ldconfig
%files
%defattr(644,root,root,755)
%doc AUTHORS CREDITS ChangeLog README* TODO
+%attr(754,root,root) /etc/rc.d/init.d/%{name}
%attr(755,root,root) %{_sbindir}/uptimed
%attr(755,root,root) %{_bindir}/uprecords
-%attr(755,root,root) %{_libdir}/*.so*
-%{_libdir}/*a
+%attr(755,root,root) %{_libdir}/lib*.so.*.*.*
+%attr(755,root,root) %ghost %{_libdir}/lib*.so.0
+#%{_libdir}/*a
%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/uptimed.conf
%{_mandir}/man*/*
%dir /var/spool/uptimed
@@ -96,6 +98,15 @@
All persons listed below can be reached at <cvs_login>@pld-linux.org
$Log$
+Revision 1.31 2012/05/16 15:22:06 blekot
+- up to 0.3.17
+- added uptimed.init for rc.scripts
+- added /sbin/ldconfig to post{,un}
+- remove bundled getopt
+- disable-static in configure
+- added temporary fix against unresolved symbol u_current
+- need review
+
Revision 1.30 2011/01/29 00:07:31 sparky
- dropped pre-cvs changelog
================================================================
---- CVS-web:
http://cvs.pld-linux.org/packages/uptimed/uptimed.spec?r1=1.30&r2=1.31
More information about the pld-cvs-commit
mailing list