When an ebuild from overlay fails, display a message indicating which overlay it...
authorZac Medico <zmedico@gentoo.org>
Thu, 8 Jun 2006 16:15:09 +0000 (16:15 -0000)
committerZac Medico <zmedico@gentoo.org>
Thu, 8 Jun 2006 16:15:09 +0000 (16:15 -0000)
svn path=/main/trunk/; revision=3473

pym/portage.py

index 3742b708f7d1257445ab3991429d4972365f66fb..787b9d20cd544c8f3c4740007cec972573b2326e 100644 (file)
@@ -3044,6 +3044,19 @@ def doebuild(myebuild, mydo, myroot, mysettings, debug=0, listonly=0,
                mysettings["DISTDIR"] = mysettings["PORTAGE_ACTUAL_DISTDIR"]
                del mysettings["PORTAGE_ACTUAL_DISTDIR"]
 
+       if retval != os.EX_OK and tree == "porttree":
+               for i in xrange(len(mydbapi.porttrees)-1):
+                       t = mydbapi.porttrees[i+1]
+                       if myebuild.startswith(t):
+                               # Display the non-cannonical path, in case it's different, to
+                               # prevent confusion.
+                               overlays = mysettings["PORTDIR_OVERLAY"].split()
+                               try:
+                                       writemsg("!!! This ebuild is from an overlay: '%s'\n" % \
+                                               overlays[i], noiselevel=-1)
+                               except KeyError:
+                                       pass
+
        return retval
 
 expandcache={}