summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2006-03-30 11:02:45 +0000
committerZac Medico <zmedico@gentoo.org>2006-03-30 11:02:45 +0000
commit20f95de43ebd561aeb460b12559f118cd82f3fb1 (patch)
tree77aa8ec408577a64854832804405679e321caf33
parentAdd patch to disable C++ bindings and nocxx useflag. (diff)
downloadgentoo-2-20f95de43ebd561aeb460b12559f118cd82f3fb1.tar.gz
gentoo-2-20f95de43ebd561aeb460b12559f118cd82f3fb1.tar.bz2
gentoo-2-20f95de43ebd561aeb460b12559f118cd82f3fb1.zip
2.1_pre7-r3 regression fix release
(Portage version: 2.1_pre7-r3)
-rw-r--r--sys-apps/portage/ChangeLog11
-rw-r--r--sys-apps/portage/Manifest33
-rw-r--r--sys-apps/portage/files/2.1_pre7/1060_r3034_bug_127897_realpath.patch27
-rw-r--r--sys-apps/portage/files/2.1_pre7/1070_r3036_bug_127930_unpack_timestamp.patch13
-rw-r--r--sys-apps/portage/files/2.1_pre7/1080_ensure_dirs.patch180
-rw-r--r--sys-apps/portage/files/digest-portage-2.1_pre7-r3 (renamed from sys-apps/portage/files/digest-portage-2.1_pre7-r2)0
-rw-r--r--sys-apps/portage/portage-2.1_pre7-r3.ebuild (renamed from sys-apps/portage/portage-2.1_pre7-r2.ebuild)7
7 files changed, 256 insertions, 15 deletions
diff --git a/sys-apps/portage/ChangeLog b/sys-apps/portage/ChangeLog
index 8ad758c15048..f0050def32f1 100644
--- a/sys-apps/portage/ChangeLog
+++ b/sys-apps/portage/ChangeLog
@@ -1,6 +1,15 @@
# ChangeLog for sys-apps/portage
# Copyright 1999-2006 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/sys-apps/portage/ChangeLog,v 1.100 2006/03/27 08:32:12 zmedico Exp $
+# $Header: /var/cvsroot/gentoo-x86/sys-apps/portage/ChangeLog,v 1.101 2006/03/30 11:02:45 zmedico Exp $
+
+*portage-2.1_pre7-r3 (30 Mar 2006)
+
+ 30 Mar 2006; <zmedico@gentoo.org> +portage-2.1_pre7-r3.ebuild,
+ +files/2.1_pre7/1060_r3034_bug_127897_realpath.patch,
+ +files/2.1_pre7/1070_r3036_bug_127930_unpack_timestamp.patch,
+ +files/2.1_pre7/1080_ensure_dirs.patch:
+ Regression fixes for bug #127897 and bug #127930. Also fixes cvs-src
+ permission messages reported by marienz.
*portage-2.1_pre7-r2 (27 Mar 2006)
diff --git a/sys-apps/portage/Manifest b/sys-apps/portage/Manifest
index fef461e336d3..7df7d5d642cb 100644
--- a/sys-apps/portage/Manifest
+++ b/sys-apps/portage/Manifest
@@ -1,9 +1,9 @@
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
-MD5 13332a042b6a2346f6d0d5f31265a369 ChangeLog 10829
-RMD160 6d693c0ea9f767beda55e51d4e84e01b57051311 ChangeLog 10829
-SHA256 89f625648c575b39359d82cfedf6046896f08cc60767f39315f0459afc56ef54 ChangeLog 10829
+MD5 a7611a31ae93551620983382aec40744 ChangeLog 11208
+RMD160 3dcd630bba234c01d5c610060f8cb08a53d4dab3 ChangeLog 11208
+SHA256 baacecd9bc70dadb0708543a99134a4a68aacebc54d2bc3440e916c740c4b576 ChangeLog 11208
MD5 d5d5b818347fd87b290ecb0b17516b34 files/05portage.envd 34
RMD160 014194a1786a0983a8ba91c3924b798f353c330d files/05portage.envd 34
SHA256 dbe8db19d03b39ad2b7f9f6dfcd24c615a14886b3fe6d5ce4dd88bac27c0e225 files/05portage.envd 34
@@ -82,6 +82,15 @@ SHA256 b1302a847c2d6ac746ec19cd09efb2cf9a38b0aa9b38f2997c958651715de1a5 files/2.
MD5 78f817f6f2dd7068087d4886ef520e60 files/2.1_pre7/1050_forum_3210399_empty_digest.patch 374
RMD160 01adefa804a8ae31c3a9c2e533accf187b0cdf3f files/2.1_pre7/1050_forum_3210399_empty_digest.patch 374
SHA256 37ac9b0b6f75f8b3f626564cb905ca57b5b2dfaa65ac7033ea5af99b158ad95a files/2.1_pre7/1050_forum_3210399_empty_digest.patch 374
+MD5 994e124a061c4ec989cb22a9e0f08a7e files/2.1_pre7/1060_r3034_bug_127897_realpath.patch 965
+RMD160 61ae23a0b1f1a1f4cd8fd8cb2401f16ef8559930 files/2.1_pre7/1060_r3034_bug_127897_realpath.patch 965
+SHA256 97eb7fa8ce0c920f68e704e33772ea329e693d573e25da03cc5b490435e835cf files/2.1_pre7/1060_r3034_bug_127897_realpath.patch 965
+MD5 5f68cba86d8f99186b15e923499c3d49 files/2.1_pre7/1070_r3036_bug_127930_unpack_timestamp.patch 409
+RMD160 4f488fb66c84ef61761645fbfdec51c6d87dce3c files/2.1_pre7/1070_r3036_bug_127930_unpack_timestamp.patch 409
+SHA256 f063bab2c9cecc497a54e030686ae74fec05ad0422b3c0f9ed707ac886520b1a files/2.1_pre7/1070_r3036_bug_127930_unpack_timestamp.patch 409
+MD5 e5c64d09695d972ae1ae9fe88a8cc625 files/2.1_pre7/1080_ensure_dirs.patch 6363
+RMD160 cd138486af48f05b38a7298dcdf264abfffba4ce files/2.1_pre7/1080_ensure_dirs.patch 6363
+SHA256 655522b977bd521d662d6650f0bfbe5f53dff44581c71bb57e6fc60fe15de0a8 files/2.1_pre7/1080_ensure_dirs.patch 6363
MD5 c906e2e6782e197725b70f84cfe112a4 files/README.RESCUE 137
RMD160 b8d015f266501fd1f57c91899c6815de9f9d5685 files/README.RESCUE 137
SHA256 69bea0c755eab59b6b4d90838b8551744f0b0c8eeac170b1cd13a71ee83f9ac4 files/README.RESCUE 137
@@ -100,9 +109,9 @@ SHA256 31fbf92704c8c3836a781144c1fe6c1a5d7a81e14fa79973821df688baf3f63d files/di
MD5 3fb2faffeb73793f7928e07619991317 files/digest-portage-2.1_pre6-r7 253
RMD160 db4da0bfd99ef42a13051e4089009e9ad3c316c2 files/digest-portage-2.1_pre6-r7 253
SHA256 bf94181b86808452bb19e43fe4d58aeeb6736924e7bd453f38c0f166b227957c files/digest-portage-2.1_pre6-r7 253
-MD5 6aebb952d3a284aa4f52d7e5dc7791de files/digest-portage-2.1_pre7-r2 253
-RMD160 437829798fb49cf829eadb8dd84fd8353eb4fdb1 files/digest-portage-2.1_pre7-r2 253
-SHA256 f96288447c0bb578ae0fb80a0169df536c3421f00df4dd8a83d2e910ca489fb5 files/digest-portage-2.1_pre7-r2 253
+MD5 6aebb952d3a284aa4f52d7e5dc7791de files/digest-portage-2.1_pre7-r3 253
+RMD160 437829798fb49cf829eadb8dd84fd8353eb4fdb1 files/digest-portage-2.1_pre7-r3 253
+SHA256 f96288447c0bb578ae0fb80a0169df536c3421f00df4dd8a83d2e910ca489fb5 files/digest-portage-2.1_pre7-r3 253
MD5 9e669b11a86a57aa8d2a452531085bb6 files/xterm-titles.patch 1115
RMD160 60cea5a3cfd37b6a3a15ced00a778defaca09212 files/xterm-titles.patch 1115
SHA256 0e23efd78cff2d7702a4e3ddcf6b53cd7de417f03234397321281066ea8c026c files/xterm-titles.patch 1115
@@ -124,13 +133,13 @@ SHA256 6f7f1500f7a6ab4a7d651a7dbe44695995fdd2a37e4c6826d5eb9de5749b458a portage-
MD5 da44da773a57bcbbe8f0c52573812d2e portage-2.1_pre6-r7.ebuild 5819
RMD160 1ad330182592ffd5637aabed39f3ba52dc29285d portage-2.1_pre6-r7.ebuild 5819
SHA256 634bed09fc46df9611027f97c3e658c6a11ab237ddc2c774bf10aadeda7f7451 portage-2.1_pre6-r7.ebuild 5819
-MD5 d5c46f8e23e1bf0417b53e817b26dfbb portage-2.1_pre7-r2.ebuild 5509
-RMD160 5681f85589dbede4d0a46889e1492731a032b54c portage-2.1_pre7-r2.ebuild 5509
-SHA256 dcf6d6c1d3d6875378efea3cf14b43957bb8b6c7d6855fb52edbfc70b5fd8d73 portage-2.1_pre7-r2.ebuild 5509
+MD5 ea76365561039705c3b43d338a5a9652 portage-2.1_pre7-r3.ebuild 5620
+RMD160 5dac64832aa76b809932fdf67c137ecbfbdc5176 portage-2.1_pre7-r3.ebuild 5620
+SHA256 083fe9fc94144cbe12edc5c302332df797c314d190858e4bc80e0a5c035530b9 portage-2.1_pre7-r3.ebuild 5620
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2.2 (GNU/Linux)
-iD8DBQFEJ6MX/ejvha5XGaMRAiNHAJ9SAirNl0ACQDwy3pIUv/vGepU2NwCfUk0y
-WqgaNEixg9TdK2RK3fBa6rc=
-=snbc
+iD8DBQFEK7nc/ejvha5XGaMRAr6LAJ4p/q1qUkA2tn16lVY6abvftSofywCgkcjm
+T2gtS9G00er2n5gN8bNvje4=
+=Z8q+
-----END PGP SIGNATURE-----
diff --git a/sys-apps/portage/files/2.1_pre7/1060_r3034_bug_127897_realpath.patch b/sys-apps/portage/files/2.1_pre7/1060_r3034_bug_127897_realpath.patch
new file mode 100644
index 000000000000..980ccc32eb5d
--- /dev/null
+++ b/sys-apps/portage/files/2.1_pre7/1060_r3034_bug_127897_realpath.patch
@@ -0,0 +1,27 @@
+=== modified file 'pym/portage_util.py'
+--- pym/portage_util.py
++++ pym/portage_util.py
+@@ -607,9 +607,21 @@
+ file when the write is interrupted (for example, when an 'out of space'
+ error occurs)."""
+
+- def __init__(self, filename, mode='w', **kargs):
++ def __init__(self, filename, mode='w', follow_links=True, **kargs):
+ """Opens a temporary filename.pid in the same directory as filename."""
+ self._aborted = False
++
++ if follow_links:
++ canonical_path = os.path.realpath(filename)
++ self._real_name = canonical_path
++ tmp_name = "%s.%i" % (canonical_path, os.getpid())
++ try:
++ super(atomic_ofstream, self).__init__(tmp_name, mode=mode, **kargs)
++ return
++ except (OSError, IOError), e:
++ writemsg("!!! Failed to open file: '%s'\n" % tmp_name)
++ writemsg("!!! %s\n" % str(e))
++
+ self._real_name = filename
+ tmp_name = "%s.%i" % (filename, os.getpid())
+ super(atomic_ofstream, self).__init__(tmp_name, mode=mode, **kargs)
+
diff --git a/sys-apps/portage/files/2.1_pre7/1070_r3036_bug_127930_unpack_timestamp.patch b/sys-apps/portage/files/2.1_pre7/1070_r3036_bug_127930_unpack_timestamp.patch
new file mode 100644
index 000000000000..b544f7a3e7c4
--- /dev/null
+++ b/sys-apps/portage/files/2.1_pre7/1070_r3036_bug_127930_unpack_timestamp.patch
@@ -0,0 +1,13 @@
+=== modified file 'bin/ebuild.sh'
+--- bin/ebuild.sh
++++ bin/ebuild.sh
+@@ -664,7 +664,7 @@
+ local checkme
+ for x in ${AA}; do
+ echo ">>> Checking ${x}'s mtime..."
+- if [ "${DISTDIR}/${x}" -nt "${WORKDIR}" ]; then
++ if [ "${PORTAGE_ACTUAL_DISTDIR:-${DISTDIR}}/${x}" -nt "${WORKDIR}" ]; then
+ echo ">>> ${x} has been updated; recreating WORKDIR..."
+ newstuff="yes"
+ rm -rf "${WORKDIR}"
+
diff --git a/sys-apps/portage/files/2.1_pre7/1080_ensure_dirs.patch b/sys-apps/portage/files/2.1_pre7/1080_ensure_dirs.patch
new file mode 100644
index 000000000000..686ac97e0a49
--- /dev/null
+++ b/sys-apps/portage/files/2.1_pre7/1080_ensure_dirs.patch
@@ -0,0 +1,180 @@
+=== modified file 'pym/portage.py'
+--- pym/portage.py
++++ pym/portage.py
+@@ -1837,29 +1837,12 @@
+ print "!!! No write access to %s" % mysettings["DISTDIR"]+"/"
+ can_fetch=False
+ else:
+- def distdir_perms(filename):
+- all_applied = True
+- try:
+- all_applied = portage_util.apply_secpass_permissions(filename, gid=portage_gid, mode=0775)
+- except portage_exception.OperationNotPermitted:
+- all_applied = False
+- if not all_applied:
+- writemsg(("!!! Unable to apply group permissions to '%s'." \
+- + " Non-root users may experience issues.\n") % filename)
+- distdir_perms(mysettings["DISTDIR"])
+ if use_locks and locks_in_subdir:
+ distlocks_subdir = os.path.join(mysettings["DISTDIR"], locks_in_subdir)
+- try:
+- distdir_perms(distlocks_subdir)
+- except portage_exception.FileNotFound:
+- os.mkdir(distlocks_subdir)
+- distdir_perms(distlocks_subdir)
+ if not os.access(distlocks_subdir, os.W_OK):
+ writemsg("!!! No write access to write to %s. Aborting.\n" % distlocks_subdir)
+ return 0
+ del distlocks_subdir
+- del distdir_perms
+-
+ for myfile in filedict.keys():
+ fetched=0
+ file_lock = None
+@@ -2594,26 +2577,13 @@
+ for subdir in kwargs["subdirs"]:
+ mydirs.append(os.path.join(basedir, subdir))
+ for mydir in mydirs:
+- if not makedirs(mydir):
+- raise portage_exception.DirectoryNotFound(
+- "Failed to create directory.")
+- try:
+- initial_stat = os.stat(mydir)
+- apply_secpass_permissions(mydir,
+- gid=portage_gid, mode=dirmode, mask=modemask, stat_cached=initial_stat)
+- result_stat = os.stat(mydir)
+- except OSError, oe:
+- if errno.EPERM == oe.errno:
+- writemsg("!!! %s\n" % oe)
+- raise portage_exception.OperationNotPermitted("stat('%s')" % mydir)
+- raise
++ modified = portage_util.ensure_dirs(mydir,
++ gid=portage_gid, mode=dirmode, mask=modemask)
+ # To avoid excessive recursive stat calls, we trigger
+ # recursion when the top level directory does not initially
+ # match our permission requirements.
+- if kwargs["always_recurse"] or \
+- result_stat.st_gid != initial_stat.st_gid or \
+- result_stat.st_mode & 07777 != initial_stat.st_mode & 07777:
+- if not kwargs["always_recurse"]:
++ if modified or kwargs["always_recurse"]:
++ if modified:
+ writemsg("Adjusting permissions recursively: '%s'" % mydir)
+ def onerror(e):
+ raise # The feature is disabled if a single error
+@@ -2804,28 +2774,29 @@
+ checkme=alist[:]
+
+ if not listonly:
+- for x in ("", "cvs-src"):
+- mydir = os.path.join(mysettings["DISTDIR"], x)
+- try:
+- os.makedirs(mydir)
+- except OSError, oe:
+- if errno.EEXIST == oe.errno:
+- pass
+- elif errno.EPERM == oe.errno:
+- writemsg("!!! %s\n" % str(oe))
+- writemsg("!!! Fetching may fail!\n")
+- else:
+- raise
++ dirmode = 02070
++ filemode = 060
++ modemask = 02
++ distdir_dirs = ["", "cvs-src"]
++ if "distlocks" in features:
++ distdir_dirs.append(".locks")
+ try:
+- apply_secpass_permissions(mysettings["DISTDIR"],
+- gid=portage_gid, mode=0775, mask=02)
+- except portage_exception.OperationNotPermitted, e:
+- writemsg("Operation Not Permitted: %s\n" % str(e))
+- except portage_exception.FileNotFound, e:
+- writemsg("File Not Found: '%s'\n" % str(e))
+-
+- apply_recursive_permissions(os.path.join(mysettings["DISTDIR"], "cvs-src"),
+- gid=portage_gid, dirmode=02770, dirmask=02, filemode=0660, filemask=02)
++
++ for x in distdir_dirs:
++ mydir = os.path.join(mysettings["DISTDIR"], x)
++ if portage_util.ensure_dirs(mydir, gid=portage_gid, mode=dirmode, mask=modemask):
++ writemsg("Adjusting permissions recursively: '%s'\n" % mydir)
++ def onerror(e):
++ raise # bail out on the first error that occurs during recursion
++ if not apply_recursive_permissions(mydir,
++ gid=portage_gid, dirmode=dirmode, dirmask=modemask,
++ filemode=filemode, filemask=modemask, onerror=onerror):
++ raise portage_exception.OperationNotPermitted(
++ "Failed to apply recursive permissions for the portage group.")
++ except portage_exception.PortageException, e:
++ writemsg("!!! %s\n" % str(e))
++ writemsg("!!! Problem adjusting permissions on DISTDIR='%s'\n" % mysettings["DISTDIR"])
++ writemsg("!!! Fetching may fail!\n")
+
+ # Only try and fetch the files if we are going to need them ... otherwise,
+ # if user has FEATURES=noauto and they run `ebuild clean unpack compile install`,
+
+=== modified file 'pym/portage_util.py'
+--- pym/portage_util.py
++++ pym/portage_util.py
+@@ -462,7 +462,10 @@
+ bits. When mask=0 is specified, mode bits on the target file are allowed
+ to be a superset of the mode argument (via logical OR). When mask>0, the
+ mode bits that the target file is allowed to have are restricted via
+- logical XOR."""
++ logical XOR.
++ Returns True if the permissions were modified and False otherwise."""
++
++ modified = False
+
+ if stat_cached is None:
+ try:
+@@ -479,6 +482,7 @@
+ (gid != -1 and gid != stat_cached.st_gid):
+ try:
+ os.chown(filename, uid, gid)
++ modified = True
+ except OSError, oe:
+ if oe.errno == errno.EPERM:
+ raise OperationNotPermitted("chown('%s', %i, %i)" % (filename, uid, gid))
+@@ -506,6 +510,7 @@
+ if new_mode != -1:
+ try:
+ os.chmod(filename, new_mode)
++ modified = True
+ except OSError, oe:
+ if oe.errno == errno.EPERM:
+ raise OperationNotPermitted("chmod('%s', %s)" % (filename, oct(new_mode)))
+@@ -513,6 +518,7 @@
+ raise FileNotFound(filename)
+ else:
+ raise
++ return modified
+
+ def apply_stat_permissions(filename, newstat, **kwargs):
+ """A wrapper around apply_secpass_permissions that gets
+@@ -680,3 +686,23 @@
+ except IOError, ioe:
+ f.abort()
+ raise ioe
++
++def ensure_dirs(dir_path, *args, **kwargs):
++ """Create a directory and call apply_permissions.
++ Returns True if a directory is created or the permissions needed to be
++ modified, and False otherwise."""
++
++ created_dir = False
++
++ try:
++ os.makedirs(dir_path)
++ created_dir = True
++ except OSError, oe:
++ if errno.EEXIST == oe.errno:
++ pass
++ elif oe.errno in (errno.EPERM, errno.EROFS):
++ raise portage_exception.OperationNotPermitted(str(oe))
++ else:
++ raise
++ perms_modified = apply_permissions(dir_path, *args, **kwargs)
++ return created_dir or perms_modified
+
diff --git a/sys-apps/portage/files/digest-portage-2.1_pre7-r2 b/sys-apps/portage/files/digest-portage-2.1_pre7-r3
index 2892d68c8269..2892d68c8269 100644
--- a/sys-apps/portage/files/digest-portage-2.1_pre7-r2
+++ b/sys-apps/portage/files/digest-portage-2.1_pre7-r3
diff --git a/sys-apps/portage/portage-2.1_pre7-r2.ebuild b/sys-apps/portage/portage-2.1_pre7-r3.ebuild
index a894e6b853ec..64f77d249ed2 100644
--- a/sys-apps/portage/portage-2.1_pre7-r2.ebuild
+++ b/sys-apps/portage/portage-2.1_pre7-r3.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2006 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/sys-apps/portage/portage-2.1_pre7-r2.ebuild,v 1.1 2006/03/27 08:32:12 zmedico Exp $
+# $Header: /var/cvsroot/gentoo-x86/sys-apps/portage/portage-2.1_pre7-r3.ebuild,v 1.1 2006/03/30 11:02:45 zmedico Exp $
inherit toolchain-funcs
@@ -36,7 +36,10 @@ src_unpack() {
1020_r3006_bug_127573_cachedir.patch
1030_r3009_bug_127563_ccache_stat.patch
1040_r3015_user_fetch.patch
- 1050_forum_3210399_empty_digest.patch"
+ 1050_forum_3210399_empty_digest.patch
+ 1060_r3034_bug_127897_realpath.patch
+ 1070_r3036_bug_127930_unpack_timestamp.patch
+ 1080_ensure_dirs.patch"
for patch_name in ${my_patches}; do
einfo "Applying ${patch_name} ..."
patch -p0 --no-backup-if-mismatch < \