summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2010-12-26 23:46:28 +0000
committerMike Frysinger <vapier@gentoo.org>2010-12-26 23:46:28 +0000
commit974fddea61a744e0b8d4847bd7ff5b9a08d0abfa (patch)
tree6d3177b6bc41e569ed8d1a71277fcc6ced1b222b /app-arch/tar
parentAutomated update of use.local.desc (diff)
downloadhistorical-974fddea61a744e0b8d4847bd7ff5b9a08d0abfa.tar.gz
historical-974fddea61a744e0b8d4847bd7ff5b9a08d0abfa.tar.bz2
historical-974fddea61a744e0b8d4847bd7ff5b9a08d0abfa.zip
Add fixes from upstream for incremental #349164 by Robin Johnson and verify #349155 by Navid Zamani.
Package-Manager: portage-2.2.0_alpha10/cvs/Linux x86_64
Diffstat (limited to 'app-arch/tar')
-rw-r--r--app-arch/tar/ChangeLog10
-rw-r--r--app-arch/tar/Manifest6
-rw-r--r--app-arch/tar/files/tar-1.25-incremental-fix.patch133
-rw-r--r--app-arch/tar/files/tar-1.25-verify-check.patch74
-rw-r--r--app-arch/tar/files/tar-1.25-verify-fix.patch43
-rw-r--r--app-arch/tar/tar-1.25-r1.ebuild75
6 files changed, 339 insertions, 2 deletions
diff --git a/app-arch/tar/ChangeLog b/app-arch/tar/ChangeLog
index f99f53a026b2..3575d4128f20 100644
--- a/app-arch/tar/ChangeLog
+++ b/app-arch/tar/ChangeLog
@@ -1,6 +1,14 @@
# ChangeLog for app-arch/tar
# Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/app-arch/tar/ChangeLog,v 1.160 2010/11/24 16:18:39 darkside Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-arch/tar/ChangeLog,v 1.161 2010/12/26 23:46:28 vapier Exp $
+
+*tar-1.25-r1 (26 Dec 2010)
+
+ 26 Dec 2010; Mike Frysinger <vapier@gentoo.org> +tar-1.25-r1.ebuild,
+ +files/tar-1.25-incremental-fix.patch, +files/tar-1.25-verify-check.patch,
+ +files/tar-1.25-verify-fix.patch:
+ Add fixes from upstream for incremental #349164 by Robin Johnson and
+ verify #349155 by Navid Zamani.
24 Nov 2010; Jeremy Olexa <darkside@gentoo.org> tar-1.25.ebuild,
files/rmt:
diff --git a/app-arch/tar/Manifest b/app-arch/tar/Manifest
index 348e6574c5e6..a34be165cd96 100644
--- a/app-arch/tar/Manifest
+++ b/app-arch/tar/Manifest
@@ -3,11 +3,15 @@ AUX tar-1.23-revert-pipe.patch 3743 RMD160 0d1945ffd7ea720c563d46199d1d0b43aeaf8
AUX tar-1.23-strncpy.patch 1249 RMD160 1e0f8fcc6152ec3cc4208a5efebdb4d97b928113 SHA1 9a4c94827703fae8572246c6380d55821db15196 SHA256 d88ba0b9d3b5dc9a8d6b70e4e71c376ff8dcd3412cb8ffceca3a722a17dbaa85
AUX tar-1.23-symlink-k-hang.patch 4936 RMD160 c58d2911e50d6ff5e88001b4755a9e4c9ba511f3 SHA1 9f4bdbf733d25982029741b8cc5b8b49a5168380 SHA256 14a5d98abc174ec5a630719e8ba55f395e91591072cba3da448e77ce9d37bbbf
AUX tar-1.23-tests.patch 662 RMD160 ef87a9f5c25240abddde45be4fb0a932c1fd2ec7 SHA1 9ab7f0d1f35ee7acd0ae74ec50c79a7dcafc03e5 SHA256 6898df207d16007233b3ed79b330e036172db7204ed35273123e87bcac7116d9
+AUX tar-1.25-incremental-fix.patch 4387 RMD160 b4ca004367e6a5ebd289a8237bb9efaeb5061c90 SHA1 2e54ce1a23a707110a2e440328f0d81743e49b32 SHA256 da801c2550a837b95ccabacd269cc9360c1c4f9d7f27fd80537c608576a112e5
+AUX tar-1.25-verify-check.patch 2083 RMD160 ef237dfe85a0f95c81d9715c791069574ef5342c SHA1 54dcaa661de4b601f6e5cb025720d3dccdbf5cd9 SHA256 4604f596b097d75c063b74c27c75c9cd5528941e2b8f904bb0743767e592c09d
+AUX tar-1.25-verify-fix.patch 1400 RMD160 e20ae093a3449bcf22a8d9591eddfa8027f7f4f0 SHA1 d39aae9a0a9e58581568e2292a41dc10c8e824a5 SHA256 eb5d28b4c10938e287476cbf6bf56a32d13043c9f6ff6ea96f91bcef46a36515
AUX tar.1 16821 RMD160 f58bc7cfeeee0cc811a6c2b5dd1dffe8b197231e SHA1 b354f0803c03cd59fe24f93d532f27f6f0136316 SHA256 f3558b444ab9427c06bc92838c29194051ed64edd0a909163cfa715cc7e6dcdd
DIST tar-1.23.tar.bz2 2189324 RMD160 e79062b7f69d80b734445306f69fb8b96801e909 SHA1 6f3b1443a019da02e4ec20a1446d4aa54b488071 SHA256 c9328372db62fbb1d94c9e4e3cefc961111af46de47085b635359c00a0eebe36
DIST tar-1.25.tar.bz2 2327460 RMD160 4798d95b8816f5b7a90af8f0596a2e6b70cacb5e SHA1 0f0c090e51d127cbeffbb9aeeb90db1181d82aed SHA256 f3f6ce41b8e0f327abd05c95990f113ddafbae131e10f79a99728ed46458494b
EBUILD tar-1.23-r2.ebuild 1757 RMD160 fe262e531e6edca865a1c49eb47bfca9f10b1edf SHA1 c2c58c2488f731adc4964fd19c6da415c93e31c5 SHA256 870839e7cfbbea1e978cb042a80b8283bffeacfe9e4f294e29591898a22ed103
EBUILD tar-1.23-r4.ebuild 1824 RMD160 6721228dfd20f85bd93278148f0f7fa7d57db84f SHA1 8fa3f45e1c85c3a06ab6062940a37f3c67ce50c0 SHA256 25bde52ba653a03f48aa26dd0d86e5879e381260b7fae24f6095de5ef55b1de0
+EBUILD tar-1.25-r1.ebuild 2250 RMD160 e52a2483470147740259dd2d8efab64dd8b844fb SHA1 1df965311d85d14655435d4aafb392a0144fd970 SHA256 30d491208882b35e3b852e14ca36d6e0f4322805fbc6cccc7a19bdcd558fdcd1
EBUILD tar-1.25.ebuild 2094 RMD160 dc0007c343c76e5acc722ddf82d4ea61e9728d9d SHA1 e92cec9a7523c59c8d6db22388dcf7040cfc3197 SHA256 4a8cb3060e514f43d1883bcceee92b8b910851825bef40b1706f7ac4cc72dbdc
-MISC ChangeLog 24161 RMD160 5c5b89d2fc80e9c31b80408e3d54e24d4e2e39bf SHA1 929efd247e04c8396a4867f41496e6a88c2cefd2 SHA256 ecfde9fe74ac2f33adaa142197ab5c859b41c4c31ca1adafd64544e2344f7dae
+MISC ChangeLog 24477 RMD160 b77fdfaeffadb4f311e4d6aefb956cde06c2ac41 SHA1 d5cd8396a1406c60126fe00a1e8f8c387ab41950 SHA256 f34cee9effbe9c81e60ef6a517a4e1cf8a5bd38bea18ce148a820f375286c549
MISC metadata.xml 164 RMD160 f43cbec30b7074319087c9acffdb9354b17b0db3 SHA1 9c213f5803676c56439df3716be07d6692588856 SHA256 f5f2891f2a4791cd31350bb2bb572131ad7235cd0eeb124c9912c187ac10ce92
diff --git a/app-arch/tar/files/tar-1.25-incremental-fix.patch b/app-arch/tar/files/tar-1.25-incremental-fix.patch
new file mode 100644
index 000000000000..0281580c3679
--- /dev/null
+++ b/app-arch/tar/files/tar-1.25-incremental-fix.patch
@@ -0,0 +1,133 @@
+http://lists.gnu.org/archive/html/bug-tar/2010-11/msg00071.html
+http://bugs.gentoo.org/349164
+
+From 065cf0958c39600f2062cbeeb5b76929d03c207b Mon Sep 17 00:00:00 2001
+From: Paul Eggert <eggert@cs.ucla.edu>
+Date: Mon, 22 Nov 2010 22:50:58 -0800
+Subject: [PATCH] * src/names.c: tar: fix bug with --one-file-system --listed-incremental
+
+Problem (and idea for fix) reported by Martin Weigel
+<http://lists.gnu.org/archive/html/bug-tar/2010-11/msg00071.html>.
+* src/common.h (is_individual_file): Remove decl.
+* src/create.c (dump_file0): Replace "is_individual_file (p)"
+with "top_level".
+* src/incremen.c (procdir): Replace "!is_individual_file
+(name_buffer)" with "st->parent". Fix bug with --one-file-system
+and --listed-incremental.
+* src/names.c (individual_file_table, register_individual_file):
+(is_individual_file): Remove. All uses removed.
+---
+ src/common.h | 1 -
+ src/create.c | 4 ++--
+ src/incremen.c | 8 ++------
+ src/names.c | 26 --------------------------
+ 4 files changed, 4 insertions(+), 35 deletions(-)
+
+diff --git a/src/common.h b/src/common.h
+index 35e056e..9444fd7 100644
+--- a/src/common.h
++++ b/src/common.h
+@@ -680,7 +680,6 @@ bool excluded_name (char const *name);
+
+ void add_avoided_name (char const *name);
+ bool is_avoided_name (char const *name);
+-bool is_individual_file (char const *name);
+
+ bool contains_dot_dot (char const *name);
+
+diff --git a/src/create.c b/src/create.c
+index a1e90a3..e8de6b9 100644
+--- a/src/create.c
++++ b/src/create.c
+@@ -1678,9 +1678,9 @@ dump_file0 (struct tar_stat_info *st, char const *name, char const *p)
+ put in the archive.
+
+ This check is omitted if incremental_option is set *and* the
+- requested file is not explicitely listed in the command line. */
++ requested file is not explicitly listed in the command line. */
+
+- if (!(incremental_option && !is_individual_file (p))
++ if (! (incremental_option && ! top_level)
+ && !S_ISDIR (st->stat.st_mode)
+ && OLDER_TAR_STAT_TIME (*st, m)
+ && (!after_date_option || OLDER_TAR_STAT_TIME (*st, c)))
+diff --git a/src/incremen.c b/src/incremen.c
+index 628ff29..2b33c5d 100644
+--- a/src/incremen.c
++++ b/src/incremen.c
+@@ -426,7 +426,6 @@ procdir (const char *name_buffer, struct tar_stat_info *st,
+ {
+ struct directory *directory;
+ struct stat *stat_data = &st->stat;
+- dev_t device = st->parent ? st->parent->stat.st_dev : 0;
+ bool nfs = NFS_FILE_STAT (*stat_data);
+
+ if ((directory = find_directory (name_buffer)) != NULL)
+@@ -540,11 +539,8 @@ procdir (const char *name_buffer, struct tar_stat_info *st,
+ }
+ }
+
+- /* If the directory is on another device and --one-file-system was given,
+- omit it... */
+- if (one_file_system_option && device != stat_data->st_dev
+- /* ... except if it was explicitely given in the command line */
+- && !is_individual_file (name_buffer))
++ if (one_file_system_option && st->parent
++ && stat_data->st_dev != st->parent->stat.st_dev)
+ /* FIXME:
+ WARNOPT (WARN_XDEV,
+ (0, 0,
+diff --git a/src/names.c b/src/names.c
+index 6e214bf..ba4d509 100644
+--- a/src/names.c
++++ b/src/names.c
+@@ -47,8 +47,6 @@ static char *cached_no_such_gname;
+ static uid_t cached_no_such_uid;
+ static gid_t cached_no_such_gid;
+
+-static void register_individual_file (char const *name);
+-
+ /* Given UID, find the corresponding UNAME. */
+ void
+ uid_to_uname (uid_t uid, char **uname)
+@@ -360,8 +358,6 @@ name_next_elt (int change_dirs)
+ {
+ if (unquote_option)
+ unquote_string (name_buffer);
+- if (incremental_option)
+- register_individual_file (name_buffer);
+ entry.type = ep->type;
+ entry.v.name = name_buffer;
+ return &entry;
+@@ -1152,28 +1148,6 @@ excluded_name (char const *name)
+ return excluded_file_name (excluded, name + FILE_SYSTEM_PREFIX_LEN (name));
+ }
+
+-static Hash_table *individual_file_table;
+-
+-static void
+-register_individual_file (char const *name)
+-{
+- struct stat st;
+-
+- if (deref_stat (name, &st) != 0)
+- return; /* Will be complained about later */
+- if (S_ISDIR (st.st_mode))
+- return;
+-
+- hash_string_insert (&individual_file_table, name);
+-}
+-
+-bool
+-is_individual_file (char const *name)
+-{
+- return hash_string_lookup (individual_file_table, name);
+-}
+-
+-
+
+ /* Return the size of the prefix of FILE_NAME that is removed after
+ stripping NUM leading file name components. NUM must be
+--
+1.7.3.1
+
diff --git a/app-arch/tar/files/tar-1.25-verify-check.patch b/app-arch/tar/files/tar-1.25-verify-check.patch
new file mode 100644
index 000000000000..31f0f7769dec
--- /dev/null
+++ b/app-arch/tar/files/tar-1.25-verify-check.patch
@@ -0,0 +1,74 @@
+From 73d0d1a0f883be5f67534362c99382f1eae8d178 Mon Sep 17 00:00:00 2001
+From: Sergey Poznyakoff <gray@gnu.org.ua>
+Date: Mon, 15 Nov 2010 11:22:27 +0200
+Subject: [PATCH] Issue a warning if the archive being compared contais transformed file names.
+
+* src/common.h (transform_program_p): New proto.
+* src/transform.c (transform_program_p): New function.
+* src/compare.c (verify_volume): Warn if the archive contains
+transformed file names.
+---
+ src/common.h | 1 +
+ src/compare.c | 13 +++++++++++--
+ src/transform.c | 6 ++++++
+ 3 files changed, 18 insertions(+), 2 deletions(-)
+
+diff --git a/src/common.h b/src/common.h
+index 69097b3..35e056e 100644
+--- a/src/common.h
++++ b/src/common.h
+@@ -779,6 +779,7 @@ void set_transform_expr (const char *expr);
+ bool transform_name (char **pinput, int type);
+ bool transform_name_fp (char **pinput, int type,
+ char *(*fun)(char *, void *), void *);
++bool transform_program_p (void);
+
+ /* Module suffix.c */
+ void set_compression_program_by_suffix (const char *name, const char *defprog);
+diff --git a/src/compare.c b/src/compare.c
+index f3112c6..91ced57 100644
+--- a/src/compare.c
++++ b/src/compare.c
+@@ -512,14 +512,23 @@ diff_archive (void)
+ void
+ verify_volume (void)
+ {
++ int may_fail = 0;
+ if (removed_prefixes_p ())
+ {
+ WARN((0, 0,
+ _("Archive contains file names with leading prefixes removed.")));
++ may_fail = 1;
++ }
++ if (transform_program_p ())
++ {
+ WARN((0, 0,
+- _("Verification may fail to locate original files.")));
++ _("Archive contains transformed file names.")));
++ may_fail = 1;
+ }
+-
++ if (may_fail)
++ WARN((0, 0,
++ _("Verification may fail to locate original files.")));
++
+ if (!diff_buffer)
+ diff_init ();
+
+diff --git a/src/transform.c b/src/transform.c
+index c35133f..77aa0a2 100644
+--- a/src/transform.c
++++ b/src/transform.c
+@@ -628,3 +628,9 @@ transform_name (char **pinput, int type)
+ {
+ return transform_name_fp (pinput, type, NULL, NULL);
+ }
++
++bool
++transform_program_p (void)
++{
++ return transform_head != NULL;
++}
+--
+1.7.3.1
+
diff --git a/app-arch/tar/files/tar-1.25-verify-fix.patch b/app-arch/tar/files/tar-1.25-verify-fix.patch
new file mode 100644
index 000000000000..5f5a81c1a7b9
--- /dev/null
+++ b/app-arch/tar/files/tar-1.25-verify-fix.patch
@@ -0,0 +1,43 @@
+http://lists.gnu.org/archive/html/bug-tar/2010-11/msg00065.html
+http://bugs.gentoo.org/349155
+
+From 24214ca5d506f56dc0cb2a2e1312256472039475 Mon Sep 17 00:00:00 2001
+From: Paul Eggert <eggert@cs.ucla.edu>
+Date: Mon, 15 Nov 2010 00:07:53 -0800
+Subject: [PATCH] tar: fix --verify option, which broke in 1.24
+
+* NEWS: Document this.
+* src/compare.c (verify_volume): Decode the header before invoking
+diff_archive, as diff_archive no longer does this as of the
+2010-06-28 commit. Also, don't try to invoke diff_archive on a
+zero block.
+* tests/Makefile.am (TESTSUITE_AT): Add verify.at.
+* tests/testsuite.at: Include verify.at.
+* tests/verify.at: New file.
+---
+ NEWS | 10 ++++++++--
+ src/compare.c | 2 ++
+ tests/Makefile.am | 1 +
+ tests/testsuite.at | 2 ++
+ tests/verify.at | 37 +++++++++++++++++++++++++++++++++++++
+ 5 files changed, 50 insertions(+), 2 deletions(-)
+ create mode 100644 tests/verify.at
+
+diff --git a/src/compare.c b/src/compare.c
+index 6b7e6d8..f3112c6 100644
+--- a/src/compare.c
++++ b/src/compare.c
+@@ -611,8 +611,10 @@ verify_volume (void)
+ (0, 0, _("A lone zero block at %s"),
+ STRINGIFY_BIGINT (current_block_ordinal (), buf)));
+ }
++ continue;
+ }
+
++ decode_header (current_header, &current_stat_info, &current_format, 1);
+ diff_archive ();
+ tar_stat_destroy (&current_stat_info);
+ }
+--
+1.7.3.1
+
diff --git a/app-arch/tar/tar-1.25-r1.ebuild b/app-arch/tar/tar-1.25-r1.ebuild
new file mode 100644
index 000000000000..51081271d51e
--- /dev/null
+++ b/app-arch/tar/tar-1.25-r1.ebuild
@@ -0,0 +1,75 @@
+# Copyright 1999-2010 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/app-arch/tar/tar-1.25-r1.ebuild,v 1.1 2010/12/26 23:46:28 vapier Exp $
+
+EAPI="3"
+
+inherit flag-o-matic
+
+DESCRIPTION="Use this to make tarballs :)"
+HOMEPAGE="http://www.gnu.org/software/tar/"
+SRC_URI="http://ftp.gnu.org/gnu/tar/${P}.tar.bz2
+ ftp://alpha.gnu.org/gnu/tar/${P}.tar.bz2
+ mirror://gnu/tar/${P}.tar.bz2"
+
+LICENSE="GPL-3"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~ppc-aix ~x86-fbsd ~x64-freebsd ~x86-freebsd ~hppa-hpux ~ia64-hpux ~x86-interix ~amd64-linux ~ia64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
+IUSE="nls static userland_GNU"
+
+RDEPEND=""
+DEPEND="${RDEPEND}
+ nls? ( >=sys-devel/gettext-0.10.35 )"
+
+src_prepare() {
+ epatch "${FILESDIR}"/${P}-incremental-fix.patch #349164
+ epatch "${FILESDIR}"/${P}-verify-fix.patch #349155
+ epatch "${FILESDIR}"/${P}-verify-check.patch
+ if ! use userland_GNU ; then
+ sed -i \
+ -e 's:/backup\.sh:/gbackup.sh:' \
+ scripts/{backup,dump-remind,restore}.in \
+ || die "sed non-GNU"
+ fi
+}
+
+src_configure() {
+ local myconf
+ use static && append-ldflags -static
+ use userland_GNU || myconf="--program-prefix=g"
+ # Work around bug in sandbox #67051
+ gl_cv_func_chown_follows_symlink=yes \
+ FORCE_UNSAFE_CONFIGURE=1 \
+ econf \
+ --enable-backup-scripts \
+ --bindir="${EPREFIX}"/bin \
+ --libexecdir="${EPREFIX}"/usr/sbin \
+ $(use_enable nls) \
+ ${myconf}
+}
+
+src_install() {
+ local p=""
+ use userland_GNU || p=g
+
+ emake DESTDIR="${D}" install || die
+
+ if [[ -z ${p} ]] ; then
+ # a nasty yet required piece of baggage
+ exeinto /etc
+ doexe "${FILESDIR}"/rmt || die
+ fi
+
+ # autoconf looks for gtar before tar (in configure scripts), hence
+ # in Prefix it is important that it is there, otherwise, a gtar from
+ # the host system (FreeBSD, Solaris, Darwin) will be found instead
+ # of the Prefix provided (GNU) tar
+ if use prefix ; then
+ dosym tar /bin/gtar
+ fi
+
+ dodoc AUTHORS ChangeLog* NEWS README* THANKS
+ newman "${FILESDIR}"/tar.1 ${p}tar.1
+ mv "${ED}"/usr/sbin/${p}backup{,-tar}
+ mv "${ED}"/usr/sbin/${p}restore{,-tar}
+}