summaryrefslogtreecommitdiffstats
path: root/pym
diff options
context:
space:
mode:
authorMarius Mauch <genone@gentoo.org>2007-06-30 10:32:36 +0000
committerMarius Mauch <genone@gentoo.org>2007-06-30 10:32:36 +0000
commit6e4dbc5df61a885fde1912f3a25fe32c6da844d6 (patch)
treea321d47b0510dd806a99d7a46b4bb7338207e96d /pym
parent656820f4b84e8dfebe3d5da133201c39a521c8fb (diff)
downloadportage-6e4dbc5df61a885fde1912f3a25fe32c6da844d6.tar.gz
portage-6e4dbc5df61a885fde1912f3a25fe32c6da844d6.tar.bz2
portage-6e4dbc5df61a885fde1912f3a25fe32c6da844d6.zip
ewarn when merging a package and the source repository/overlay does not have a name
svn path=/main/trunk/; revision=7097
Diffstat (limited to 'pym')
-rw-r--r--pym/portage/dbapi/vartree.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/pym/portage/dbapi/vartree.py b/pym/portage/dbapi/vartree.py
index 64fafbb57..6e3c8736a 100644
--- a/pym/portage/dbapi/vartree.py
+++ b/pym/portage/dbapi/vartree.py
@@ -24,6 +24,8 @@ from portage import listdir, dep_expand, flatten, key_expand, \
doebuild_environment, doebuild, env_update, \
abssymlink, movefile, _movefile, bsd_chflags
+from portage.elog.messages import ewarn
+
import os, sys, stat, errno, commands, copy, time
from itertools import izip
@@ -1703,12 +1705,16 @@ class dblink(object):
repopath = os.sep.join(self.settings["O"].split(os.sep)[:-2])
# bindbapi has no getRepositories() method
if mydbapi and hasattr(mydbapi, "getRepositories"):
+ foundname = False
for reponame in mydbapi.getRepositories():
if mydbapi.getRepositoryPath(reponame) == repopath:
fd = open(os.path.join(self.dbtmpdir, "repository"), "w")
fd.write(reponame+"\n")
fd.close()
+ foundname = True
break
+ if not foundname:
+ ewarn("Could not determine name of source repository at %s" % repopath, phase="preinst", key=self.mycpv)
# write local package counter for recording
lcfile = open(os.path.join(self.dbtmpdir, "COUNTER"),"w")