From 0d322b7940daba847431e64839c5af44a7bf6006 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Miloslav=20Trma=C4=8D?= Date: Thu, 26 Aug 2010 22:31:57 +0200 Subject: [PATCH] Update to mlocate-0.23 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Thu Aug 26 2010 Miloslav Trmač - 0.23-1 - Update to mlocate-0.23 - Don't exclude rootfs, to avoid ambiguity when handling "/" Resolves: #624551 --- mlocate-0.22.4-noop-bind.patch | 39 ---------------------------------- mlocate.cron | 2 +- mlocate.spec | 12 ++++++----- 3 files changed, 8 insertions(+), 45 deletions(-) delete mode 100644 mlocate-0.22.4-noop-bind.patch diff --git a/mlocate-0.22.4-noop-bind.patch b/mlocate-0.22.4-noop-bind.patch deleted file mode 100644 index 591f32f..0000000 --- a/mlocate-0.22.4-noop-bind.patch +++ /dev/null @@ -1,39 +0,0 @@ -Ignore no-op bind mounts. - -2010-03-30 Miloslav Trmač - - * src/updatedb.c (rebuild_bind_mount_paths): Ignore no-op bind mounts. - * doc/updatedb.conf.5.in (PRUNE_BIND_MOUNTS): Document that no-op bind - mounts are not skipped. - -diff -r f505e36861d7 -r 87bcb87d48f9 doc/updatedb.conf.5.in ---- a/doc/updatedb.conf.5.in Fri Mar 26 20:16:16 2010 +0100 -+++ b/doc/updatedb.conf.5.in Tue Mar 30 15:36:08 2010 +0200 -@@ -96,6 +96,7 @@ - .BR updatedb (8). - All file systems mounted in the subtree of a bind mount are skipped as well, - even if they are not bind mounts. -+As an exception, bind mounts of a directory on itself are not skipped. - - By default, bind mounts are not skipped. - -diff -r f505e36861d7 -r 87bcb87d48f9 src/updatedb.c ---- a/src/updatedb.c Fri Mar 26 20:16:16 2010 +0100 -+++ b/src/updatedb.c Tue Mar 30 15:36:08 2010 +0200 -@@ -370,8 +370,14 @@ - { - if (conf_debug_pruning != false) - /* This is debuging output, don't mark anything for translation */ -- fprintf (stderr, " `%s', opts `%s'\n", me->mnt_dir, me->mnt_opts); -- if (hasmntopt (me, "bind") != NULL) -+ fprintf (stderr, " `%s' on `%s', opts `%s'\n", me->mnt_fsname, -+ me->mnt_dir, me->mnt_opts); -+ /* Bind mounts "to self" can be used (e.g. by policycoreutils-sandbox) to -+ create another mount point to which Linux name space privacy flags can -+ be attached. Such a bind mount is not duplicating any part of the -+ directory tree, so it should not be excluded. */ -+ if (hasmntopt (me, "bind") != NULL -+ && strcmp (me->mnt_fsname, me->mnt_dir) != 0) - { - char dbuf[PATH_MAX], *dir; - diff --git a/mlocate.cron b/mlocate.cron index 6a338e1..ffd1a07 100644 --- a/mlocate.cron +++ b/mlocate.cron @@ -1,5 +1,5 @@ #!/bin/sh -nodevs=$(< /proc/filesystems awk '$1 == "nodev" { print $2 }') +nodevs=$(< /proc/filesystems awk '$1 == "nodev" && $2 != "rootfs" { print $2 }') renice +19 -p $$ >/dev/null 2>&1 ionice -c2 -n7 -p $$ >/dev/null 2>&1 /usr/bin/updatedb -f "$nodevs" diff --git a/mlocate.spec b/mlocate.spec index e3784c2..711103e 100644 --- a/mlocate.spec +++ b/mlocate.spec @@ -1,13 +1,11 @@ Summary: An utility for finding files by name Name: mlocate -Version: 0.22.4 -Release: 2%{?dist} +Version: 0.23 +Release: 1%{?dist} License: GPLv2 URL: https://fedorahosted.org/mlocate/ Group: Applications/System Source0: https://fedorahosted.org/releases/m/l/mlocate/mlocate-%{version}.tar.xz -# Upstream changeset 87bcb87d48f939b851bdcf9580dfa89fe03438e7 -Patch0: mlocate-0.22.4-noop-bind.patch Source1: updatedb.conf Source2: mlocate.cron Requires(pre): shadow-utils @@ -25,7 +23,6 @@ trash the system caches as much as traditional locate implementations. %prep %setup -q -%patch0 -p1 -b .noop-bind %build %configure --localstatedir=%{_localstatedir}/lib @@ -70,6 +67,11 @@ exit 0 %ghost %{_localstatedir}/lib/mlocate/mlocate.db %changelog +* Thu Aug 26 2010 Miloslav Trmač - 0.23-1 +- Update to mlocate-0.23 +- Don't exclude rootfs, to avoid ambiguity when handling "/" + Resolves: #624551 + * Tue Mar 30 2010 Miloslav Trmač - 0.22.4-2 - Ignore no-op bind mounts Resolves: #577819