diff --git a/.gitignore b/.gitignore index 059d6e7..e42ed91 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,2 @@ findutils-4.5.9.tar.gz +/findutils-4.5.10.tar.gz diff --git a/findutils-4.4.0-no-locate.patch b/findutils-4.4.0-no-locate.patch index 6452fb9..b33ff9b 100644 --- a/findutils-4.4.0-no-locate.patch +++ b/findutils-4.4.0-no-locate.patch @@ -1,3 +1,13 @@ +From dc92679e2c363f8c0d659fa428c138684455a6bd Mon Sep 17 00:00:00 2001 +From: Kamil Dudka +Date: Wed, 11 May 2011 16:46:13 +0200 +Subject: [PATCH 1/4] findutils-4.4.0-no-locate.patch + +--- + Makefile.am | 2 +- + doc/find.texi | 24 ++++++++---------------- + 2 files changed, 9 insertions(+), 17 deletions(-) + diff --git a/Makefile.am b/Makefile.am index c7f8f39..0dacb93 100644 --- a/Makefile.am @@ -12,7 +22,7 @@ index c7f8f39..0dacb93 100644 ACLOCAL_AMFLAGS = -I gnulib/m4 -I m4 diff --git a/doc/find.texi b/doc/find.texi -index d719ccb..b509f66 100644 +index 1f278de..c584298 100644 --- a/doc/find.texi +++ b/doc/find.texi @@ -7,7 +7,6 @@ @@ -33,7 +43,7 @@ index d719ccb..b509f66 100644 @table @code @item --database=@var{path} -@@ -2728,13 +2726,9 @@ thrashing the network. +@@ -2825,13 +2823,9 @@ thrashing the network. directories are indexed by each database file. The default location for the locate database depends on how findutils @@ -50,7 +60,7 @@ index d719ccb..b509f66 100644 @node Database Formats @section Database Formats -@@ -3213,8 +3207,7 @@ present. +@@ -3310,8 +3304,7 @@ present. @item --database=@var{path} @itemx -d @var{path} @@ -60,7 +70,7 @@ index d719ccb..b509f66 100644 name databases in @var{path}, which is a colon-separated list of database file names. You can also use the environment variable @code{LOCATE_PATH} to set the list of database files to search. The -@@ -3399,8 +3392,7 @@ The environment variable @code{PRUNEFS} also sets this value. Default +@@ -3496,8 +3489,7 @@ The environment variable @code{PRUNEFS} also sets this value. Default is @file{nfs NFS proc}. @item --output=@var{dbfile} @@ -70,7 +80,7 @@ index d719ccb..b509f66 100644 @item --localuser=@var{user} The user to search the non-network directories as, using @code{su}. -@@ -5359,7 +5351,7 @@ See the description of the similar message for @code{find}. +@@ -5491,7 +5483,7 @@ why @code{xargs} is confused by your operating system). @section Error Messages From @code{locate} @table @samp @@ -79,7 +89,7 @@ index d719ccb..b509f66 100644 The @code{locate} program relies on a database which is periodically built by the @code{updatedb} program. That hasn't happened in a long time. To fix this problem, run @code{updatedb} manually. This can -@@ -5367,7 +5359,7 @@ often happen on systems that are generally not left on, so the +@@ -5499,7 +5491,7 @@ often happen on systems that are generally not left on, so the periodic ``cron'' task which normally does this doesn't get a chance to run. @@ -88,3 +98,6 @@ index d719ccb..b509f66 100644 This should not happen. Re-run @code{updatedb}. If that works, but @code{locate} still produces this error, run @code{locate --version} and @code{updatedb --version}. These should produce the same output. +-- +1.7.4.4 + diff --git a/findutils-4.4.2-autofs.patch b/findutils-4.4.2-autofs.patch index a850c20..85c973d 100644 --- a/findutils-4.4.2-autofs.patch +++ b/findutils-4.4.2-autofs.patch @@ -1,5 +1,14 @@ +From 113d6b31623db33fbea65e586f5bfaf1ea1c8d30 Mon Sep 17 00:00:00 2001 +From: Kamil Dudka +Date: Wed, 11 May 2011 16:46:32 +0200 +Subject: [PATCH 2/4] findutils-4.4.2-autofs.patch + +--- + find/fstype.c | 69 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ + 1 files changed, 69 insertions(+), 0 deletions(-) + diff --git a/find/fstype.c b/find/fstype.c -index 21c446b..502e208 100644 +index c6dbe8b..9cbf620 100644 --- a/find/fstype.c +++ b/find/fstype.c @@ -205,7 +205,72 @@ must_read_fs_list (bool need_fs_type) @@ -86,3 +95,6 @@ index 21c446b..502e208 100644 /* Don't cache unknown values. */ fstype_known = (type != NULL); +-- +1.7.4.4 + diff --git a/findutils-4.4.2-xautofs.patch b/findutils-4.4.2-xautofs.patch index 7192298..72e2f1b 100644 --- a/findutils-4.4.2-xautofs.patch +++ b/findutils-4.4.2-xautofs.patch @@ -1,3 +1,9 @@ +From 17e470dc1acca4824b70328d733d5f99c12d0d65 Mon Sep 17 00:00:00 2001 +From: Kamil Dudka +Date: Wed, 11 May 2011 16:46:45 +0200 +Subject: [PATCH 3/4] findutils-4.4.2-xautofs.patch + +--- doc/find.texi | 4 ++++ find/defs.h | 3 +++ find/find.1 | 3 +++ @@ -7,7 +13,7 @@ 6 files changed, 27 insertions(+), 1 deletions(-) diff --git a/doc/find.texi b/doc/find.texi -index b509f66..3ce5b1e 100644 +index c584298..9731b71 100644 --- a/doc/find.texi +++ b/doc/find.texi @@ -1438,6 +1438,10 @@ them. @@ -36,7 +42,7 @@ index 11d1d00..f95ce72 100644 * no longer exists by the time we get around to processing it. */ diff --git a/find/find.1 b/find/find.1 -index 5da6ddf..82dc802 100644 +index e851f82..a4799ff 100644 --- a/find/find.1 +++ b/find/find.1 @@ -460,6 +460,9 @@ if standard input is a tty, and to @@ -67,7 +73,7 @@ index 9fdb8ef..bd7cc37 100644 { /* this is the preorder visit, but user said -depth */ diff --git a/find/parser.c b/find/parser.c -index 3da5721..b14b59a 100644 +index 52a1ef6..995aec3 100644 --- a/find/parser.c +++ b/find/parser.c @@ -151,6 +151,7 @@ static bool parse_user (const struct parser_table*, char *argv[], int * @@ -95,7 +101,7 @@ index 3da5721..b14b59a 100644 puts (_("\ tests (N can be +N or -N or N): -amin N -anewer FILE -atime N -cmin N\n\ -cnewer FILE -ctime N -empty -false -fstype TYPE -gid N -group NAME\n\ -@@ -2795,6 +2797,13 @@ parse_xdev (const struct parser_table* entry, char **argv, int *arg_ptr) +@@ -2800,6 +2802,13 @@ parse_xdev (const struct parser_table* entry, char **argv, int *arg_ptr) } static bool @@ -121,3 +127,6 @@ index 8577396..4d45f84 100644 p->ignore_readdir_race = false; if (p->posixly_correct) +-- +1.7.4.4 + diff --git a/findutils-4.5.10.tar.gz.sig b/findutils-4.5.10.tar.gz.sig new file mode 100644 index 0000000..9c56a74 Binary files /dev/null and b/findutils-4.5.10.tar.gz.sig differ diff --git a/findutils-4.5.7-warnings.patch b/findutils-4.5.7-warnings.patch index 152e4d9..b1e61b0 100644 --- a/findutils-4.5.7-warnings.patch +++ b/findutils-4.5.7-warnings.patch @@ -1,12 +1,18 @@ +From 1b7065f25457fea9f9ee7100437b12815b92a38c Mon Sep 17 00:00:00 2001 +From: Kamil Dudka +Date: Wed, 11 May 2011 16:46:57 +0200 +Subject: [PATCH 4/4] findutils-4.5.7-warnings.patch + +--- find/pred.c | 6 +++--- xargs/xargs.c | 5 +++-- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/find/pred.c b/find/pred.c -index e310eea..6eeaa42 100644 +index 3acfe9f..ee3c245 100644 --- a/find/pred.c +++ b/find/pred.c -@@ -566,7 +566,7 @@ impl_pred_exec (const char *pathname, +@@ -561,7 +561,7 @@ impl_pred_exec (const char *pathname, struct predicate *pred_ptr) { struct exec_val *execp = &pred_ptr->args.exec_vec; @@ -15,7 +21,7 @@ index e310eea..6eeaa42 100644 bool result; const bool local = is_exec_in_local_dir (pred_ptr->pred_func); char *prefix; -@@ -665,7 +665,7 @@ impl_pred_exec (const char *pathname, +@@ -660,7 +660,7 @@ impl_pred_exec (const char *pathname, if (target != pathname) { assert (local); @@ -24,7 +30,7 @@ index e310eea..6eeaa42 100644 } return result; } -@@ -2111,7 +2111,7 @@ launch (struct buildcmd_control *ctl, void *usercontext, int argc, char **argv) +@@ -2106,7 +2106,7 @@ launch (struct buildcmd_control *ctl, void *usercontext, int argc, char **argv) } } @@ -34,10 +40,10 @@ index e310eea..6eeaa42 100644 else execvp (argv[0], argv); diff --git a/xargs/xargs.c b/xargs/xargs.c -index c53b5a9..a0d90a5 100644 +index 3cc1832..35f6822 100644 --- a/xargs/xargs.c +++ b/xargs/xargs.c -@@ -1105,7 +1105,7 @@ xargs_do_exec (struct buildcmd_control *ctl, void *usercontext, int argc, char * +@@ -1132,7 +1132,7 @@ xargs_do_exec (struct buildcmd_control *ctl, void *usercontext, int argc, char * prep_child_for_exec (); @@ -46,7 +52,7 @@ index c53b5a9..a0d90a5 100644 errno = E2BIG; else execvp (argv[0], argv); -@@ -1123,7 +1123,8 @@ xargs_do_exec (struct buildcmd_control *ctl, void *usercontext, int argc, char * +@@ -1150,7 +1150,8 @@ xargs_do_exec (struct buildcmd_control *ctl, void *usercontext, int argc, char * * utility if we run it, for POSIX compliance on the * handling of exit values. */ @@ -56,3 +62,6 @@ index c53b5a9..a0d90a5 100644 } close (fd[1]); +-- +1.7.4.4 + diff --git a/findutils-4.5.9-execdir.patch b/findutils-4.5.9-execdir.patch deleted file mode 100644 index 4fa157a..0000000 --- a/findutils-4.5.9-execdir.patch +++ /dev/null @@ -1,106 +0,0 @@ - ChangeLog | 18 ++++++++++++++++++ - NEWS | 4 ++++ - find/pred.c | 10 ++++------ - find/testsuite/find.gnu/execdir-multiple.exp | 1 + - lib/dircallback.c | 7 ++++++- - 5 files changed, 33 insertions(+), 7 deletions(-) - -diff --git a/ChangeLog b/ChangeLog -index ba12e93..e2451c4 100644 ---- a/ChangeLog -+++ b/ChangeLog -@@ -1,3 +1,21 @@ -+2010-05-24 Kamil Dudka -+ -+ Fix Savannah bug #29949, -execdir does not change working directory -+ * find/pred.c (record_exec_dir): Do not throw the execdir when not -+ working in the cumulative mode. -+ * find/testsuite/find.gnu/execdir-multiple.exp: Add a test-case for -+ the bug #29949. -+ * NEWS: Mention this bugfix. -+ -+2010-05-07 Kamil Dudka -+ -+ * lib/dircallback.c (run_in_dir): Make sure that if the callback -+ doesn't get run, the return value is nonzero. Make sure that if -+ the directory save/restore fails, we don't overwrite errno with a -+ random value (and hence report some unrelated and nonexistent -+ error, instead of the real problem). Restore the previous current -+ directory. -+ - 2010-04-29 James Youngman - - Prepare for the release of findutils version 4.5.9. -diff --git a/NEWS b/NEWS -index e27a834..cae1eab 100644 ---- a/NEWS -+++ b/NEWS -@@ -1,5 +1,9 @@ - GNU findutils NEWS - User visible changes. -*- outline -*- (allout) - -+** Bug Fixes -+ -+#29949: find -execdir does not change working directory -+ - * Major changes in release 4.5.9, 2010-04-29 - - ** Bug Fixes -diff --git a/find/pred.c b/find/pred.c -index 6eeaa42..0efb55f 100644 ---- a/find/pred.c -+++ b/find/pred.c -@@ -528,13 +528,11 @@ initialise_wd_for_exec (struct exec_val *execp, int cwd_fd, const char *dir) - static bool - record_exec_dir (struct exec_val *execp) - { -- if (!execp->wd_for_exec) -+ /* working directory not already known, so must be a *dir variant, -+ and this must be the first arg we added. However, this may -+ be -execdir foo {} \; (i.e. not multiple). */ -+ if (!execp->state.todo) - { -- /* working directory not already known, so must be a *dir variant, -- and this must be the first arg we added. However, this may -- be -execdir foo {} \; (i.e. not multiple). */ -- assert (!execp->state.todo); -- - /* Record the WD. If we're using -L or fts chooses to do so for - any other reason, state.cwd_dir_fd may in fact not be the - directory containing the target file. When this happens, -diff --git a/find/testsuite/find.gnu/execdir-multiple.exp b/find/testsuite/find.gnu/execdir-multiple.exp -index 6d4bd66..495b93b 100644 ---- a/find/testsuite/find.gnu/execdir-multiple.exp -+++ b/find/testsuite/find.gnu/execdir-multiple.exp -@@ -49,6 +49,7 @@ if { [ safe_path ] } { - } - - set SKIP_OLD 1 -+ find_start p {tmp -type f -empty -execdir sh ./runme \{\} \; } "" - find_start p {tmp -type f -empty -execdir sh ./runme \{\} + } "" - set SKIP_OLD 0 - exec rm -rf tmp -diff --git a/lib/dircallback.c b/lib/dircallback.c -index 8497bee..c1e4088 100644 ---- a/lib/dircallback.c -+++ b/lib/dircallback.c -@@ -37,7 +37,8 @@ int - run_in_dir (const struct saved_cwd *there, - int (*callback)(void*), void *usercontext) - { -- int err, saved_errno; -+ int err = -1; -+ int saved_errno = 0; - struct saved_cwd here; - if (0 == save_cwd (&here)) - { -@@ -50,6 +51,10 @@ run_in_dir (const struct saved_cwd *there, - { - openat_restore_fail (errno); - } -+ -+ if (restore_cwd (&here) != 0) -+ openat_restore_fail (errno); -+ - free_cwd (&here); - } - else diff --git a/findutils.spec b/findutils.spec index 7392284..2cd5c28 100644 --- a/findutils.spec +++ b/findutils.spec @@ -1,7 +1,7 @@ Summary: The GNU versions of find utilities (find and xargs) Name: findutils -Version: 4.5.9 -Release: 3%{?dist} +Version: 4.5.10 +Release: 1%{?dist} Epoch: 1 License: GPLv3+ Group: Applications/File @@ -23,10 +23,6 @@ Patch3: findutils-4.4.2-xautofs.patch # eliminate compile-time warnings Patch4: findutils-4.5.7-warnings.patch -# fix some bugs in handling of -execdir, including upstream commit 443487e -# and the proposed fix for https://savannah.gnu.org/bugs/index.php?29949 -Patch5: findutils-4.5.9-execdir.patch - Requires(post): /sbin/install-info Requires(preun): /sbin/install-info Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) @@ -53,7 +49,6 @@ useful for finding things on your system. %patch2 -p1 %patch3 -p1 %patch4 -p1 -%patch5 -p1 # needed because of findutils-4.4.0-no-locate.patch aclocal -I gnulib/m4 -I m4 @@ -103,7 +98,7 @@ rm -rf $RPM_BUILD_ROOT %files -f %{name}.lang %defattr(-,root,root,-) -%doc AUTHORS COPYING NEWS README THANKS TODO +%doc AUTHORS COPYING NEWS README THANKS TODO ChangeLog /bin/find %{_bindir}/find %{_bindir}/oldfind @@ -114,6 +109,9 @@ rm -rf $RPM_BUILD_ROOT %{_infodir}/find-maint.info.gz %changelog +* Wed May 11 2011 Kamil Dudka - 1:4.5.10-1 +- new upstream release + * Tue Feb 08 2011 Fedora Release Engineering - 1:4.5.9-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild diff --git a/sources b/sources index dba8475..90b1ebe 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -f0276639a824f57e78916d3c207ee618 findutils-4.5.9.tar.gz +06bd1e0c0026e134c591c07de83dd94b findutils-4.5.10.tar.gz