aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNicholas Jones <carpaski@gentoo.org>2004-09-30 03:04:35 +0000
committerNicholas Jones <carpaski@gentoo.org>2004-09-30 03:04:35 +0000
commit16822c11dabec164b64e99f6caaa158ca3d4825d (patch)
treef3cc50de979359ec28e0c97b5ad16bff8d8a974b
parentAdded unicode-rxvt to the list of legal term types. #65762 (diff)
downloadportage-cvs-16822c11dabec164b64e99f6caaa158ca3d4825d.tar.gz
portage-cvs-16822c11dabec164b64e99f6caaa158ca3d4825d.tar.bz2
portage-cvs-16822c11dabec164b64e99f6caaa158ca3d4825d.zip
_rc7, rsync and webrsync is the primary changes.yportage_2_0_51_rc7
-rw-r--r--ChangeLog23
-rwxr-xr-xbin/emerge10
-rwxr-xr-xbin/emerge-webrsync21
-rw-r--r--pym/portage.py20
-rw-r--r--pym/portage_db_template.py4
5 files changed, 55 insertions, 23 deletions
diff --git a/ChangeLog b/ChangeLog
index b03bd03..e020170 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,12 +1,25 @@
# ChangeLog for Portage; the Gentoo Linux ports system
# Copyright 2000-2004 Gentoo Technologies, Inc.; Distributed under the GPL v2
-# $Id: ChangeLog,v 1.765 2004/09/29 13:54:51 jstubbs Exp $
+# $Id: ChangeLog,v 1.766 2004/09/30 03:04:34 carpaski Exp $
MAJOR CHANGES in 2.0.51:
1. /var/cache/edb/virtuals is no longer used at all. It's calculated now.
2. /var/cache/edb/world is now /var/lib/portage/world.
3. /etc/portage/profile/virtuals is _USER_ configs only.
+ 30 Sep 2004; Nicholas Jones <carpaski@gentoo.org> emerge: Rsync fix part 2
+ for the distfiles, local, and packages directory unlinks.
+
+ 30 Sep 2004; Nicholas Jones <carpaski@gentoo.org> emerge-webrsync: Fix for
+ the missing md5sum causing failure to download. Fixed up a couple messages.
+ Modified the local rsync line.
+
+ 30 Sep 2004; Nicholas Jones <carpaski@gentoo.org> portage.py: Make more of
+ the chown calls friendly. More output on strange exceptions in aux_get.
+
+ 30 Sep 2004; Nicholas Jones <carpaski@gentoo.org> portage_db_template.py:
+ Added some more putput to the corruption message.
+
29 Sep 2004; Jason Stubbs <jstubbs@gentoo.org> output.py: Added unicode-rxvt
to the list of legal term types. #65762
@@ -17,7 +30,7 @@
26 Sep 2004; Nicholas Jones <carpaski@gentoo.org> emerge: Restart fix for
the -a into execv code.
-
+
26 Sep 2004; Nicholas Jones <carpaski@gentoo.org> portage_locks.py: Fixed
a traceback for Fat32 users.
@@ -74,7 +87,7 @@
26 Sep 2004; Nicholas Jones <carpaski@gentoo.org> portage_lock.py: Added
more cleanup to the lockfile descriptors.
-*portage-2.0.51_rc2 (25 Sep 2004): And we another Release Candidate!
+*portage-2.0.51_rc2 (25 Sep 2004): And we have another Release Candidate!
25 Sep 2004; Nicholas Jones <carpaski@gentoo.org> portage_db_flat.py: Fix
for typos.
@@ -139,6 +152,8 @@
getmaskingstatus() to use settings.prevmaskdict rather than reading packages
directly in support of cascading profiles.
+*portage-2.0.51_rc1 (25 Sep 2004): And we have a Release Candidate!
+
15 Sep 2004; Nicholas Jones <carpaski@gentoo.org> ebuild: On merge, disable
the noauto feature explicitly.
@@ -680,7 +695,7 @@
to the titlebar terminals.
02 Aug 2004; Nicholas Jones <carpaski@gentoo.org> portage.py: Added a message
- regarding the location of the virtuals file (move to /etc/portage/profiles).
+ regarding the location of the virtuals file (move to /etc/portage/profile).
Added a invalid-mirror message and a missing URI message for fetching. Added
the selinux sandbox patch. Removed the old dep_opconvert call as all ?:
syntax is gone.
diff --git a/bin/emerge b/bin/emerge
index e5a2b26..86d0eaa 100755
--- a/bin/emerge
+++ b/bin/emerge
@@ -1,7 +1,7 @@
#!/usr/bin/python -O
# Copyright 1999-2003 Gentoo Technologies, Inc.
# Distributed under the terms of the GNU General Public License v2
-# $Header: /local/data/ulm/cvs/history/var/cvsroot/gentoo-src/portage/bin/emerge,v 1.332 2004/09/27 05:44:05 carpaski Exp $
+# $Header: /local/data/ulm/cvs/history/var/cvsroot/gentoo-src/portage/bin/emerge,v 1.333 2004/09/30 03:04:34 carpaski Exp $
import os,sys
os.environ["PORTAGE_CALLER"]="emerge"
@@ -1002,7 +1002,7 @@ class depgraph:
elif not "--oneshot" in myopts:
myfavorites.append(mykey)
else:
- try:
+ try:
mykey=portage.dep_expand(x,portage.portdb)
except ValueError, errpkgs:
print "\n\n!!! The short ebuild name \"" + x + "\" is ambiguous. Please specify"
@@ -2259,9 +2259,9 @@ if myaction in ["sync","rsync","metadata"] and (not "--help" in myopts):
"--delete-after", # Delete only after everything else is done
"--stats", # Show final statistics about what was transfered
"--timeout="+str(mytimeout), # IO timeout if not done in X seconds
- "--exclude='distfiles/*'", # Exclude distfiles from consideration
- "--exclude='local/*'", # Exclude local from consideration
- "--exclude='packages/*'", # Exclude packages from consideration
+ "--exclude='/distfiles'", # Exclude distfiles from consideration
+ "--exclude='/local'", # Exclude local from consideration
+ "--exclude='/packages'", # Exclude packages from consideration
]
if "--quiet" in myopts:
diff --git a/bin/emerge-webrsync b/bin/emerge-webrsync
index 56d2d35..40f5672 100755
--- a/bin/emerge-webrsync
+++ b/bin/emerge-webrsync
@@ -1,7 +1,7 @@
#!/bin/sh
# Copyright 1999-2003 Gentoo Technologies, Inc.
# Distributed under the terms of the GNU General Public License v2
-# $Header: /local/data/ulm/cvs/history/var/cvsroot/gentoo-src/portage/bin/Attic/emerge-webrsync,v 1.6 2004/08/13 08:05:45 ferringb Exp $
+# $Header: /local/data/ulm/cvs/history/var/cvsroot/gentoo-src/portage/bin/Attic/emerge-webrsync,v 1.7 2004/09/30 03:04:35 carpaski Exp $
# Author: Karl Trygve Kalleberg <karltk@gentoo.org>
# Rewritten from the old, Perl-based emerge-webrsync script
@@ -18,7 +18,6 @@ fi
cd "$DISTDIR"
found=0
-attempts=0
if [ "$1" == "-v" ] ; then
wgetops=
else
@@ -49,7 +48,8 @@ sync_local() {
chown -R 0:0 portage
cd portage
rsync -av --progress --stats --delete --delete-after \
- --exclude='distfiles/*' --exclude='packages/*' . ${PORTDIR%%/}
+ --exclude='/distfiles' --exclude='/packages' \
+ --exclude='/local' . ${PORTDIR%%/}
cd ..
echo "cleaning up"
rm -rf portage
@@ -59,7 +59,9 @@ sync_local() {
echo "Fetching most recent snapshot"
+declare -i attempts=-1
while (( $attempts < 40 )) ; do
+ attempts=$(( attempts + 1 ))
#this too, sucks. it works in the interim though.
if [ "$USERLAND" == "BSD" ] ; then
@@ -74,6 +76,8 @@ while (( $attempts < 40 )) ; do
fi
FILE_ORIG="portage-${year}${month}${day}.tar.bz2"
+
+ echo "Attempting to fetch file dated: ${year}${month}${day}"
got_md5=0
@@ -92,15 +96,15 @@ while (( $attempts < 40 )) ; do
FILE="${FILE_ORIG}"
if (($got_md5 == 0 )); then
- echo "unable to fetch md5sum, no way to detect corruption. bailing"
- exit 1
+ echo " --- No md5sum present on the mirror. (Not yet available.)"
+ continue
elif [ -s "${FILE}" ]; then
if eval "$md5_com"; then
- echo "existing snapshot $FILE is correct, using it"
+ echo " === snapshot $FILE is correct, using it"
sync_local
echo
- echo " *** Reused snapshot $FILE"
- ehco
+ echo " === Snapshot has beed sync'd"
+ echo
exit 0
else
rm $FILE
@@ -126,7 +130,6 @@ while (( $attempts < 40 )) ; do
fi
done
- attempts=$[attempts+1]
done
rm -rf portage
diff --git a/pym/portage.py b/pym/portage.py
index b66376b..5095bbb 100644
--- a/pym/portage.py
+++ b/pym/portage.py
@@ -1,7 +1,7 @@
# portage.py -- core Portage functionality
# Copyright 1998-2003 Daniel Robbins, Gentoo Technologies, Inc.
# Distributed under the GNU Public License v2
-# $Header: /local/data/ulm/cvs/history/var/cvsroot/gentoo-src/portage/pym/portage.py,v 1.513 2004/09/27 01:59:19 carpaski Exp $
+# $Header: /local/data/ulm/cvs/history/var/cvsroot/gentoo-src/portage/pym/portage.py,v 1.514 2004/09/30 03:04:35 carpaski Exp $
# ===========================================================================
# START OF CONSTANTS -- START OF CONSTANTS -- START OF CONSTANTS -- START OF
@@ -1738,7 +1738,10 @@ def fetch(myuris, mysettings, listonly=0, fetchonly=0, locks_in_subdir=".locks",
#if root, -always- set the perms.
if os.path.exists(mysettings["DISTDIR"]+"/"+myfile) and (fetched != 1 or os.getuid() == 0):
if os.stat(mysettings["DISTDIR"]+"/"+myfile).st_gid != portage_gid:
- os.chown(mysettings["DISTDIR"]+"/"+myfile,-1,portage_gid)
+ try:
+ os.chown(mysettings["DISTDIR"]+"/"+myfile,-1,portage_gid)
+ except:
+ portage_util.writemsg("chown failed on distfile: " + str(myfile))
os.chmod(mysettings["DISTDIR"]+"/"+myfile,0664)
if mydigests!=None and mydigests.has_key(myfile):
@@ -4925,7 +4928,13 @@ class portdbapi(dbapi):
mylock = portage_locks.lockfile(mydbkey, wantnewlockfile=1)
if os.path.exists(mydbkey):
- os.unlink(mydbkey)
+ try:
+ os.unlink(mydbkey)
+ except Exception, e:
+ portage_locks.unlockfile(mylock)
+ self.lock_held = 0
+ writemsg("Uncaught handled exception: %(exception)s\n" % {"exception":str(e)})
+ raise
myret=doebuild(myebuild,"depend","/",self.mysettings,dbkey=mydbkey)
if myret:
@@ -4947,6 +4956,11 @@ class portdbapi(dbapi):
writemsg(str(red("\naux_get():")+" (1) Error in "+mycpv+" ebuild.\n"
" Check for syntax error or corruption in the ebuild. (--debug)\n\n"))
raise KeyError
+ except Exception, e:
+ portage_locks.unlockfile(mylock)
+ self.lock_held = 0
+ writemsg("Uncaught handled exception: %(exception)s\n" % {"exception":str(e)})
+ raise
portage_locks.unlockfile(mylock)
self.lock_held = 0
diff --git a/pym/portage_db_template.py b/pym/portage_db_template.py
index 835bb24..0d5bce6 100644
--- a/pym/portage_db_template.py
+++ b/pym/portage_db_template.py
@@ -1,4 +1,4 @@
-# $Header: /local/data/ulm/cvs/history/var/cvsroot/gentoo-src/portage/pym/Attic/portage_db_template.py,v 1.8 2004/09/25 13:07:55 carpaski Exp $
+# $Header: /local/data/ulm/cvs/history/var/cvsroot/gentoo-src/portage/pym/Attic/portage_db_template.py,v 1.9 2004/09/30 03:04:35 carpaski Exp $
import os.path,string
from portage_util import getconfig, ReadOnlyConfig
@@ -69,7 +69,7 @@ class database:
self.__addCache(key,values)
return values
except Exception, e:
- raise CorruptionError("Corruption detected when reading key '%s'" % (key))
+ raise CorruptionError("Corruption detected when reading key '%s': %s" % (key,str(e)))
raise KeyError("Key not in db: '%s'" % (key))
def __setitem__(self,key,values):