summaryrefslogtreecommitdiffstats
path: root/bin
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2008-03-28 13:05:40 +0000
committerZac Medico <zmedico@gentoo.org>2008-03-28 13:05:40 +0000
commit8839a0f0bfb9b669d56b39c7ffb045046123075c (patch)
tree800708528d8971a2a319f6fc705675315e4e3d19 /bin
parentc192360e121c3b652d25f907b29d5174842a253d (diff)
downloadportage-8839a0f0bfb9b669d56b39c7ffb045046123075c.tar.gz
portage-8839a0f0bfb9b669d56b39c7ffb045046123075c.tar.bz2
portage-8839a0f0bfb9b669d56b39c7ffb045046123075c.zip
Bug #213629 - Create an EAPI.incompatible category and use it in cases
where EAPI=0 and a slot atom is encountered. (trunk r9524) svn path=/main/branches/2.1.2/; revision=9576
Diffstat (limited to 'bin')
-rwxr-xr-xbin/repoman15
1 files changed, 12 insertions, 3 deletions
diff --git a/bin/repoman b/bin/repoman
index cb6c7efc9..cc558d691 100755
--- a/bin/repoman
+++ b/bin/repoman
@@ -173,6 +173,7 @@ qahelp={
"LICENSE.missing":"Ebuilds that have a missing or empty LICENSE variable",
"DESCRIPTION.missing":"Ebuilds that have a missing or empty DESCRIPTION variable",
"DESCRIPTION.toolong":"DESCRIPTION is over %d characters" % max_desc_len,
+ "EAPI.incompatible":"Ebuilds that use features that are only available with a different EAPI",
"EAPI.unsupported":"Ebuilds that have an unsupported EAPI version (you must upgrade portage)",
"SLOT.missing":"Ebuilds that have a missing or empty SLOT variable",
"HOMEPAGE.missing":"Ebuilds that have a missing or empty HOMEPAGE variable",
@@ -1461,6 +1462,7 @@ for x in scanlist:
continue
myaux = ebuild_metadata[y]
+ eapi = myaux["EAPI"]
# Test for negative logic and bad words in the RESTRICT var.
#for x in myaux[allvars.index("RESTRICT")].split():
@@ -1632,15 +1634,22 @@ for x in scanlist:
if myteststr.find(token) != -1:
badsyntax.append("'%s' not separated by space" % (token))
-
if mytype in ("DEPEND", "RDEPEND", "PDEPEND"):
for token in mydepstr.split():
if token in operator_tokens or \
token.endswith("?"):
continue
- if not portage.isvalidatom(token, allow_blockers=True) or \
- ":" in token and myaux["EAPI"] == "0":
+ if not portage.isvalidatom(token, allow_blockers=True):
badsyntax.append("'%s' not a valid atom" % token)
+ else:
+ atom = token.lstrip("!")
+ if eapi == "0":
+ if portage_dep.dep_getslot(atom):
+ stats['EAPI.incompatible'] += 1
+ fails['EAPI.incompatible'].append(
+ (relative_path + ": %s slot dependency" + \
+ " not supported with EAPI='%s':" + \
+ " '%s'") % (mytype, eapi, atom))
type_list.extend([mytype] * (len(badsyntax) - len(type_list)))