summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2005-04-05 03:51:08 +0000
committerMike Frysinger <vapier@gentoo.org>2005-04-05 03:51:08 +0000
commit1e57dd07365731c691cf3c1331090fcfbc1f598f (patch)
tree2668a8191c16c9b9609c46be98ce21499911a946 /app-arch
parentNew version: 14.48. Added 18.47 to x86. (diff)
downloadgentoo-2-1e57dd07365731c691cf3c1331090fcfbc1f598f.tar.gz
gentoo-2-1e57dd07365731c691cf3c1331090fcfbc1f598f.tar.bz2
gentoo-2-1e57dd07365731c691cf3c1331090fcfbc1f598f.zip
Version bump to fix tempfile bugs #87939.
(Portage version: 2.0.51.19)
Diffstat (limited to 'app-arch')
-rw-r--r--app-arch/sharutils/ChangeLog9
-rw-r--r--app-arch/sharutils/files/digest-sharutils-4.2.1-r111
-rw-r--r--app-arch/sharutils/files/sharutils-4.2.1-gentoo.patch29
-rw-r--r--app-arch/sharutils/files/sharutils-4.2.1-tempfile.patch126
-rw-r--r--app-arch/sharutils/sharutils-4.2.1-r11.ebuild63
5 files changed, 204 insertions, 24 deletions
diff --git a/app-arch/sharutils/ChangeLog b/app-arch/sharutils/ChangeLog
index 7883c1ad22ea..a4d8ec60ecbe 100644
--- a/app-arch/sharutils/ChangeLog
+++ b/app-arch/sharutils/ChangeLog
@@ -1,6 +1,13 @@
# ChangeLog for app-arch/sharutils
# Copyright 2002-2005 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/app-arch/sharutils/ChangeLog,v 1.25 2005/01/01 11:57:58 eradicator Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-arch/sharutils/ChangeLog,v 1.26 2005/04/05 03:51:08 vapier Exp $
+
+*sharutils-4.2.1-r11 (05 Apr 2005)
+
+ 05 Apr 2005; Mike Frysinger <vapier@gentoo.org>
+ files/sharutils-4.2.1-gentoo.patch, +files/sharutils-4.2.1-tempfile.patch,
+ +sharutils-4.2.1-r11.ebuild:
+ Version bump to fix tempfile bugs #87939.
28 Dec 2004; Ciaran McCreesh <ciaranm@gentoo.org> :
Change encoding to UTF-8 for GLEP 31 compliance
diff --git a/app-arch/sharutils/files/digest-sharutils-4.2.1-r11 b/app-arch/sharutils/files/digest-sharutils-4.2.1-r11
new file mode 100644
index 000000000000..afb942300ec9
--- /dev/null
+++ b/app-arch/sharutils/files/digest-sharutils-4.2.1-r11
@@ -0,0 +1 @@
+MD5 b8ba1d409f07edcb335ff72a27bd9828 sharutils-4.2.1.tar.gz 306022
diff --git a/app-arch/sharutils/files/sharutils-4.2.1-gentoo.patch b/app-arch/sharutils/files/sharutils-4.2.1-gentoo.patch
index 6f8ef97973b1..a183c79bc93e 100644
--- a/app-arch/sharutils/files/sharutils-4.2.1-gentoo.patch
+++ b/app-arch/sharutils/files/sharutils-4.2.1-gentoo.patch
@@ -1,6 +1,5 @@
-diff -r -C2 sharutils-4.2.1.orig/doc/remsync.texi sharutils-4.2.1/doc/remsync.texi
-*** sharutils-4.2.1.orig/doc/remsync.texi Thu Nov 30 18:15:37 1995
---- sharutils-4.2.1/doc/remsync.texi Fri Aug 3 18:57:02 2001
+*** sharutils-4.2.1/doc/remsync.texi
+--- sharutils-4.2.1/doc/remsync.texi
***************
*** 8,11 ****
--- 8,15 ----
@@ -12,9 +11,8 @@ diff -r -C2 sharutils-4.2.1.orig/doc/remsync.texi sharutils-4.2.1/doc/remsync.te
+ @end direntry
This file documents the @code{remsync} command and friends, which have
the purpose of synchronizing remote directory trees using email.
-diff -r -C2 sharutils-4.2.1.orig/doc/sharutils.texi sharutils-4.2.1/doc/sharutils.texi
-*** sharutils-4.2.1.orig/doc/sharutils.texi Fri Nov 24 21:42:52 1995
---- sharutils-4.2.1/doc/sharutils.texi Fri Aug 3 18:29:43 2001
+*** sharutils-4.2.1/doc/sharutils.texi
+--- sharutils-4.2.1/doc/sharutils.texi
***************
*** 16,31 ****
@@ -41,8 +39,8 @@ diff -r -C2 sharutils-4.2.1.orig/doc/sharutils.texi sharutils-4.2.1/doc/sharutil
! @end direntry
@end ifinfo
---- sharutils-4.2.1/src/uudecode.c.orig Sat Apr 13 01:26:31 2002
-+++ sharutils-4.2.1/src/uudecode.c Sat Apr 13 01:30:32 2002
+--- sharutils-4.2.1/src/uudecode.c
++++ sharutils-4.2.1/src/uudecode.c
@@ -81,6 +81,9 @@
/* Single character decode. */
#define DEC(Char) (((Char) - ' ') & 077)
@@ -88,18 +86,3 @@ diff -r -C2 sharutils-4.2.1.orig/doc/sharutils.texi sharutils-4.2.1/doc/sharutil
---- sharutils-4.2.1/src/mailshar.in.orig Fri May 11 21:45:29 2001
-+++ sharutils-4.2.1/src/mailshar.in Fri May 11 21:50:40 2001
-@@ -33,7 +33,11 @@
- If none of -MTBzZ are given, -z is automatically selected if *none*
- of the FILEs have an .arc, .exz, .gif, .z, .gz, .Z, .zip or .zoo suffix."
-
--temp=/usr/tmp/$$.shar
-+temp=`mktemp -q /tmp/$0.XXXXXX`
-+if [ $? -ne 0 ]; then
-+ echo "$0: Can't create temp file, exiting..."
-+ exit 1
-+fi
-
- ### Decode the options.
-
diff --git a/app-arch/sharutils/files/sharutils-4.2.1-tempfile.patch b/app-arch/sharutils/files/sharutils-4.2.1-tempfile.patch
new file mode 100644
index 000000000000..1b49c7fa40aa
--- /dev/null
+++ b/app-arch/sharutils/files/sharutils-4.2.1-tempfile.patch
@@ -0,0 +1,126 @@
+Ripped from Ubuntu's patch:
+http://security.ubuntu.com/ubuntu/pool/main/s/sharutils/sharutils_4.2.1-10ubuntu0.2.diff.gz
+
+To fix bug:
+http://bugs.gentoo.org/show_bug.cgi?id=87939
+
+--- sharutils-4.2.1/doc/shar.1
++++ sharutils-4.2.1/doc/shar.1
+@@ -48,7 +48,7 @@
+ the list of files to be packed. For example:
+ .nf
+
+-find . \-type f \-print | sort | shar \-S \-Z \-L50 \-o /tmp/big
++find . \-type f \-print | sort | shar \-S \-Z \-L50 \-o /somewhere/big
+
+ .fi
+ If \f2\-p\f1 is specified on the command line, then the options
+--- sharutils-4.2.1/doc/sharutils.texi
++++ sharutils-4.2.1/doc/sharutils.texi
+@@ -219,7 +214,7 @@
+ the list of files to be packed. For example:
+
+ @example
+-find . -type f -print | shar -S -o /tmp/big.shar
++find . -type f -print | shar -S -o /somewhere/big.shar
+ @end example
+
+ If @code{-p} is specified on the command line, then the options
+--- sharutils-4.2.1/src/remsync.in
++++ sharutils-4.2.1/src/remsync.in
+@@ -1657,7 +1657,10 @@
+ }
+ }
+
+- open (SCAN, ("find$list -type f -print 2> /tmp/$$.find"
++ $findtempfile = `tempfile`;
++ chop $findtempfile;
++
++ open (SCAN, ("find$list -type f -print 2> $findtempfile"
+ . " | xargs $sum_command |"))
+ || &interrupt ("Cannot launch program \`find\'");
+
+@@ -1689,7 +1692,7 @@
+
+ # Clean out scanning for inexisting files.
+
+- open (SCAN, "/tmp/$$.find");
++ open (SCAN, "$findtempfile");
+ while (<SCAN>)
+ {
+ chop;
+@@ -1706,7 +1709,7 @@
+ &query ("Should I delete this scan (y/n)? [y]");
+ if (/^(y|yes)$/i)
+ {
+- &delete_scan ($file);
++ &command_delete_scan ($file);
+ }
+ else
+ {
+@@ -1720,7 +1723,7 @@
+ }
+ }
+ close SCAN;
+- unlink "/tmp/$$.find";
++ unlink "$findtempfile";
+
+ $study_files = 0;
+ }
+--- sharutils-4.2.1/src/unshar.c
++++ sharutils-4.2.1/src/unshar.c
+@@ -424,13 +424,15 @@
+ }
+ else
+ {
++#ifdef __MSDOS__
+ sprintf (name_buffer, "/tmp/unsh.%05d", (int) getpid ());
+ unlink (name_buffer);
+
+ if (file = fopen (name_buffer, "w+"), !file)
+ error (EXIT_FAILURE, errno, name_buffer);
+-#ifndef __MSDOS__
+- unlink (name_buffer); /* will be deleted on fclose */
++#else
++ if (file = tmpfile(), !file)
++ error (EXIT_FAILURE, errno, "tmpfile");
+ #endif
+
+ while (size_read = fread (copy_buffer, 1, sizeof (copy_buffer), stdin),
+--- sharutils-4.2.1/src/uudecode.c
++++ sharutils-4.2.1/src/uudecode.c
+@@ -292,12 +292,12 @@
+
+ if (strncmp (buf, "begin", 5) == 0)
+ {
+- if (sscanf (buf, "begin-base64 %o %s", &mode, buf) == 2)
++ if (sscanf (buf, "begin-base64 %o %[^\n]", &mode, buf) == 2)
+ {
+ do_base64 = 1;
+ break;
+ }
+- else if (sscanf (buf, "begin %o %s", &mode, buf) == 2)
++ else if (sscanf (buf, "begin %o %[^\n]", &mode, buf) == 2)
+ break;
+ }
+ }
+@@ -348,7 +348,7 @@
+ #endif
+ ))
+ {
+- error (0, errno, "%s: %s", outname, inname);
++ error (0, errno, "%s", outname);
+ return 1;
+ }
+
+--- sharutils-4.2.1/src/mailshar.in
++++ sharutils-4.2.1/src/mailshar.in
+@@ -33,7 +33,7 @@
+ If none of -MTBzZ are given, -z is automatically selected if *none*
+ of the FILEs have an .arc, .exz, .gif, .z, .gz, .Z, .zip or .zoo suffix."
+
+-temp=/usr/tmp/$$.shar
++temp=`tempfile`
+
+ ### Decode the options.
+
diff --git a/app-arch/sharutils/sharutils-4.2.1-r11.ebuild b/app-arch/sharutils/sharutils-4.2.1-r11.ebuild
new file mode 100644
index 000000000000..34bb58c9de9f
--- /dev/null
+++ b/app-arch/sharutils/sharutils-4.2.1-r11.ebuild
@@ -0,0 +1,63 @@
+# Copyright 1999-2005 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/app-arch/sharutils/sharutils-4.2.1-r11.ebuild,v 1.1 2005/04/05 03:51:08 vapier Exp $
+
+inherit eutils
+
+DESCRIPTION="Tools to deal with shar archives"
+HOMEPAGE="http://www.gnu.org/software/sharutils/"
+SRC_URI="mirror://gentoo/${P}.tar.gz
+ mirror://gnu/${PN}/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86"
+IUSE="nls"
+
+DEPEND="sys-apps/texinfo
+ nls? ( >=sys-devel/gettext-0.10.35 )"
+
+src_unpack() {
+ unpack ${A}
+ cd "${S}"
+ epatch "${FILESDIR}"/${P}-gentoo.patch
+ epatch "${FILESDIR}"/${P}-buffer-check.patch #46998
+ epatch "${FILESDIR}"/${P}-buffer-limits.patch #65773
+ epatch "${FILESDIR}"/${P}-tempfile.patch #87939
+
+ cd "${S}"/po
+ cp ja_JP.EUC.po ja.po
+ cp ja_JP.EUC.gmo ja.gmo
+ sed -i \
+ -e 's/aangemaakt/aangemaakt\\n/' \
+ nl.po || die "sed nl.po failed"
+ sed -i \
+ -e 's/de %dk/de %dk\\n/' \
+ pt.po || die "sed pt.po failed"
+}
+
+src_compile() {
+ econf $(use_enable nls) || die
+ emake || die "emake failed"
+}
+
+src_install() {
+ local x=
+
+ einstall \
+ localedir=${D}/usr/share/locale \
+ || die
+
+ doman doc/*.[15]
+ # Remove some strange locales
+ cd ${D}/usr/share/locale
+ for x in *.
+ do
+ rm -rf ${x}
+ done
+ rm -rf ${D}/usr/lib
+
+ cd ${S}
+ dodoc AUTHORS BACKLOG ChangeLog ChangeLog.OLD \
+ NEWS README README.OLD THANKS TODO
+}