aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2009-03-24 02:48:27 +0000
committerZac Medico <zmedico@gentoo.org>2009-03-24 02:48:27 +0000
commita4828ac20dc2a71a60e8918c88afdea1845f7779 (patch)
treebc3a50e789a23c4e823c81f4049cef582a9e349f /bin/ebuild
parentIf a package is masked by EAPI then don't show any other masking reasons. (diff)
downloadportage-a4828ac20dc2a71a60e8918c88afdea1845f7779.tar.gz
portage-a4828ac20dc2a71a60e8918c88afdea1845f7779.tar.bz2
portage-a4828ac20dc2a71a60e8918c88afdea1845f7779.zip
Add support for FEATURES=parse-eapi-glep-55. This feature is only intended for
experimental purposes and should not be enabled under normal circumstances. svn path=/main/trunk/; revision=13175
Diffstat (limited to 'bin/ebuild')
-rwxr-xr-xbin/ebuild14
1 files changed, 9 insertions, 5 deletions
diff --git a/bin/ebuild b/bin/ebuild
index 55736dd3a..8e1d4432f 100755
--- a/bin/ebuild
+++ b/bin/ebuild
@@ -83,7 +83,14 @@ if portage.settings["NOCOLOR"] in ("yes","true") or not sys.stdout.isatty():
ebuild = pargs.pop(0)
-if not ebuild.endswith(".ebuild"):
+pf = None
+if 'parse-eapi-glep-55' in portage.settings.features:
+ pf, eapi = portage._split_ebuild_name_glep55(
+ os.path.basename(ebuild))
+elif ebuild.endswith(".ebuild"):
+ pf = os.path.basename(ebuild)[:-7]
+
+if pf is None:
portage.writemsg("'%s' does not end with '.ebuild'.\n" % \
(ebuild,), noiselevel=-1)
sys.exit(1)
@@ -120,8 +127,7 @@ if not os.path.exists(ebuild):
sys.exit(1)
ebuild_split = ebuild.split("/")
-del ebuild_split[-2]
-cpv = "/".join(ebuild_split[-2:])[:-7]
+cpv = "%s/%s" % (ebuild_split[-3], pf)
if not portage.catpkgsplit(cpv):
print "!!! %s does not follow correct package syntax." % (cpv)
@@ -158,8 +164,6 @@ def discard_digests(myebuild, mysettings, mydbapi):
portage._doebuild_manifest_exempt_depend += 1
pkgdir = os.path.dirname(myebuild)
fetchlist_dict = portage.FetchlistDict(pkgdir, mysettings, mydbapi)
- cat, pkg = pkgdir.split(os.sep)[-2:]
- cpv = cat + "/" + os.path.basename(myebuild)[:-7]
from portage.manifest import Manifest
mf = Manifest(pkgdir, mysettings["DISTDIR"],
fetchlist_dict=fetchlist_dict, manifest1_compat=False)