rpms/e2fsprogs/devel e2fsprogs-1.40.4-uuidd-tidy.patch, NONE, 1.1 uuidd.init, NONE, 1.1 e2fsprogs.spec, 1.91, 1.92
Eric Sandeen (sandeen)
fedora-extras-commits at redhat.com
Mon Jan 14 20:23:17 UTC 2008
Author: sandeen
Update of /cvs/pkgs/rpms/e2fsprogs/devel
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv21475
Modified Files:
e2fsprogs.spec
Added Files:
e2fsprogs-1.40.4-uuidd-tidy.patch uuidd.init
Log Message:
* Tue Jan 09 2008 Eric Sandeen <sandeen at redhat.com> 1.40.4-3
- New uuidd subpackage, and properly set up uuidd at install.
e2fsprogs-1.40.4-uuidd-tidy.patch:
--- NEW FILE e2fsprogs-1.40.4-uuidd-tidy.patch ---
Index: e2fsprogs-1.39/misc/uuidd.8.in
===================================================================
--- e2fsprogs-1.39.orig/misc/uuidd.8.in
+++ e2fsprogs-1.39/misc/uuidd.8.in
@@ -64,11 +64,11 @@ UUID's.
.TP
.BI \-p " pidfile"
Specify the pathname where the pid file should be written. By default,
-the pid file is written to /var/run/uuidd.pid.
+the pid file is written to /var/lib/libuuid/uuidd.pid.
.TP
.BI \-s " socketpath"
Specify the pathname used for the unix-domain socket used by uuidd. By
-qdefault, the pathname used is /var/run/uuidd.sock. This is primarily
+default, the pathname used is /var/lib/libuuid/uuidd.sock. This is primarily
for debugging purposes, since the pathname is hard-coded in the libuuid
library.
.TP
--- NEW FILE uuidd.init ---
#!/bin/bash
#
# uuidd uuidd daemon for unique time-based UUID generation
#
# Author: Eric Sandeen <sandeen at redhat.com>
#
# chkconfig: 2345 60 99
#
# description: uuidd is a helper daemon to guarantee uniqueness of \
# time-based UUIDs when using libuuid.
# processname: uuidd
# pidfile: /var/lib/libuuid/uuidd.pid
#
### BEGIN INIT INFO
# Provides: uuidd
# Required-Start: $time $local_fs
# Required-Stop: $time $local_fs
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: UUID daemon
# Description: Daemon which guarantees uniqueness of time-based UUIDS
# when using libuuid.
### END INIT INFO
# source function library
. /etc/rc.d/init.d/functions
RETVAL=0
DAEMON=uuidd
start() {
echo -n $"Starting uuidd: "
daemon --user uuidd --pidfile /var/lib/libuuid/uuidd.pid /usr/sbin/uuidd
RETVAL=$?
echo
[ $RETVAL -eq 0 ] && touch /var/lock/subsys/uuidd
}
stop() {
echo -n $"Stopping uuidd: "
killproc uuidd
echo
[ $RETVAL -eq 0 ] && rm -f /var/lock/subsys/uuidd
}
restart() {
stop
start
}
case "$1" in
start)
start
;;
stop)
stop
;;
restart|force-reload|reload)
restart
;;
condrestart)
[ -f /var/lock/subsys/uuidd ] && restart
;;
status)
status -p /var/lib/libuuid/uuidd.pid uuidd uuidd
REVAL=$?
;;
*)
echo $"Usage: $0 {start|stop|status|restart|reload|force-reload|condrestart}"
exit 1
esac
exit $RETVAL
Index: e2fsprogs.spec
===================================================================
RCS file: /cvs/pkgs/rpms/e2fsprogs/devel/e2fsprogs.spec,v
retrieving revision 1.91
retrieving revision 1.92
diff -u -r1.91 -r1.92
--- e2fsprogs.spec 1 Jan 2008 22:52:42 -0000 1.91
+++ e2fsprogs.spec 14 Jan 2008 20:22:37 -0000 1.92
@@ -4,7 +4,7 @@
Summary: Utilities for managing the second and third extended (ext2/ext3) filesystems
Name: e2fsprogs
Version: 1.40.4
-Release: 2%{?dist}
+Release: 3%{?dist}
# License based on upstream-modified COPYING file,
# which clearly states "V2" intent.
License: GPLv2
@@ -12,9 +12,11 @@
Source0: http://downloads.sourceforge.net/%{name}/%{name}-%{version}.tar.gz
Source1: ext2_types-wrapper.h
Source2: blkid_types-wrapper.h
-Patch34: e2fsprogs-1.39-blkid-devmapper.patch
-Patch36: e2fsprogs-1.38-etcblkid.patch
-Patch62: e2fsprogs-1.39-mkinstalldirs.patch
+Source3: uuidd.init
+Patch1: e2fsprogs-1.39-blkid-devmapper.patch
+Patch2: e2fsprogs-1.38-etcblkid.patch
+Patch3: e2fsprogs-1.39-mkinstalldirs.patch
+Patch4: e2fsprogs-1.40.4-uuidd-tidy.patch
Url: http://e2fsprogs.sourceforge.net/
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
@@ -72,14 +74,28 @@
filesystem-specific programs. If you install e2fsprogs-devel, you'll
also want to install e2fsprogs.
+%package -n uuidd
+Summary: helper daemon to guarantee uniqueness of time-based UUIDs
+Group: System Environment/Daemons
+Requires: e2fsprogs-libs = %{version}-%{release}
+License: GPLv2
+Requires(pre): shadow-utils
+
+%description -n uuidd
+The uuidd package contains a userspace daemon (uuidd) which guarantees
+uniqueness of time-based UUID generation even at very high rates on
+SMP systems.
+
%prep
%setup -q -n e2fsprogs-%{version}
# look at device mapper devices
-%patch34 -p1 -b .dm
+%patch1 -p1 -b .dm
# put blkid.tab in /etc/blkid/
-%patch36 -p1 -b .etcblkid
+%patch2 -p1 -b .etcblkid
# Fix for newer autoconf (#220715)
-%patch62 -p1 -b .mkinstalldirs
+%patch3 -p1 -b .mkinstalldirs
+# uuidd manpage tidyup
+%patch4 -p1 -b .uuidd-tidy
%build
aclocal
@@ -102,6 +118,11 @@
$RPM_BUILD_ROOT%{_includedir}/blkid/blkid_types-%{_arch}.h
install -p -m 644 %{SOURCE2} $RPM_BUILD_ROOT%{_includedir}/blkid/blkid_types.h
+# Our own initscript for uuidd
+install -m 755 %{SOURCE3} $RPM_BUILD_ROOT/etc/init.d/uuidd
+# And a dir uuidd needs that the makefiles don't create
+install -d $RPM_BUILD_ROOT/var/lib/libuuid
+
%find_lang %{name}
%check
@@ -130,6 +151,23 @@
fi
exit 0
+%pre -n uuidd
+getent group uuidd >/dev/null || groupadd -r uuidd
+getent passwd uuidd >/dev/null || \
+useradd -r -g uuidd -d /var/lib/libuuid -s /sbin/nologin \
+ -c "UUID generator helper daemon" uuidd
+exit 0
+
+%post -n uuidd
+/sbin/chkconfig --add uuidd
+
+%preun -n uuidd
+if [ "$1" = 0 ]
+then
+ /sbin/service uuidd stop > /dev/null 2>&1 || :
+ /sbin/chkconfig --del uuidd
+fi
+
%files -f %{name}.lang
%defattr(-,root,root)
%doc README RELEASE-NOTES
@@ -155,7 +193,6 @@
%{_root_sbindir}/tune2fs
%{_sbindir}/filefrag
%{_sbindir}/mklost+found
-%{_sbindir}/uuidd
%{_bindir}/chattr
%{_bindir}/lsattr
@@ -186,7 +223,6 @@
%{_mandir}/man8/mklost+found.8*
%{_mandir}/man8/resize2fs.8*
%{_mandir}/man8/tune2fs.8*
-%{_mandir}/man8/uuidd.8*
%files libs
%defattr(-,root,root)
@@ -241,7 +277,17 @@
%{_mandir}/man3/uuid_time.3*
%{_mandir}/man3/uuid_unparse.3*
+%files -n uuidd
+%defattr(-,root,root)
+/etc/init.d/uuidd
+%{_mandir}/man8/uuidd.8*
+%attr(-, uuidd, uuidd) %{_sbindir}/uuidd
+%dir %attr(2775, uuidd, uuidd) /var/lib/libuuid
+
%changelog
+* Tue Jan 09 2008 Eric Sandeen <sandeen at redhat.com> 1.40.4-3
+- New uuidd subpackage, and properly set up uuidd at install.
+
* Tue Jan 01 2008 Eric Sandeen <esandeen at redhat.com> 1.40.4-2
- Add new uidd files to specfile
More information about the fedora-extras-commits
mailing list