summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2009-03-11 05:07:40 +0000
committerZac Medico <zmedico@gentoo.org>2009-03-11 05:07:40 +0000
commit1c9620566480cfb4ce708d73c45297835bc66c3c (patch)
tree680a17776c260cc788d005ae575b849a1f5ed2aa
parent* Remove outdated comment about qa_source() return value (with typo). (diff)
downloadportage-multirepo-1c9620566480cfb4ce708d73c45297835bc66c3c.tar.gz
portage-multirepo-1c9620566480cfb4ce708d73c45297835bc66c3c.tar.bz2
portage-multirepo-1c9620566480cfb4ce708d73c45297835bc66c3c.zip
Add a new "portage.internal" warning for prepalldocs usage since the council
ruled that it shouldn't be used in ebuilds. Thanks to Petteri Räty <betelgeuse@g.o> for the initial patch. (trunk r12603) svn path=/main/branches/2.1.6/; revision=12884
-rwxr-xr-xbin/repoman1
-rw-r--r--man/repoman.13
-rw-r--r--pym/repoman/checks.py11
-rw-r--r--pym/repoman/errors.py1
4 files changed, 15 insertions, 1 deletions
diff --git a/bin/repoman b/bin/repoman
index 0f24fbaf..bc0997dc 100755
--- a/bin/repoman
+++ b/bin/repoman
@@ -317,6 +317,7 @@ qahelp={
"metadata.missing":"Missing metadata.xml files",
"metadata.bad":"Bad metadata.xml files",
"metadata.warning":"Warnings in metadata.xml files",
+ "portage.internal":"The ebuild uses an internal Portage function",
"virtual.versioned":"PROVIDE contains virtuals with versions",
"virtual.exists":"PROVIDE contains existing package names",
"virtual.unavailable":"PROVIDE contains a virtual which contains no profile default",
diff --git a/man/repoman.1 b/man/repoman.1
index b8b8f5de..df9d6b07 100644
--- a/man/repoman.1
+++ b/man/repoman.1
@@ -270,6 +270,9 @@ Missing metadata.xml files
.B metadata.warning
Warnings in metadata.xml files
.TP
+.B portage.internal
+The ebuild uses an internal Portage function
+.TP
.B upstream.workaround
The ebuild works around an upstream bug, an upstream bug should be filed and
tracked in bugs.gentoo.org
diff --git a/pym/repoman/checks.py b/pym/repoman/checks.py
index e8902098..aee6d7c9 100644
--- a/pym/repoman/checks.py
+++ b/pym/repoman/checks.py
@@ -339,6 +339,15 @@ class WantAutoDefaultValue(LineCheck):
return 'WANT_AUTO' + m.group(1) + \
' redundantly set to default value "latest" on line: %d'
+class PortageInternal(LineCheck):
+ """
+ In February 2009 the Gentoo council ruled that
+ prepalldocs is a Portage internal.
+ """
+ repoman_check_name = 'portage.internal'
+ re = re.compile(r'[^#]*\bprepalldocs\b')
+ error = errors.PREPALLDOCS_ERROR
+
_constant_checks = tuple((c() for c in (
EbuildHeader, EbuildWhitespace, EbuildQuote,
EbuildAssignment, EbuildUselessDodoc,
@@ -346,7 +355,7 @@ _constant_checks = tuple((c() for c in (
EbuildPatches, EbuildQuotedA,
IUseUndefined, ImplicitRuntimeDeps, InheritAutotools,
EMakeParallelDisabled, DeprecatedBindnowFlags,
- WantAutoDefaultValue)))
+ WantAutoDefaultValue, PortageInternal)))
def run_checks(contents, pkg):
checks = _constant_checks
diff --git a/pym/repoman/errors.py b/pym/repoman/errors.py
index 7f45bea2..20591395 100644
--- a/pym/repoman/errors.py
+++ b/pym/repoman/errors.py
@@ -15,3 +15,4 @@ PATCHES_ERROR = 'PATCHES is not a bash array on line: %d'
REDUNDANT_CD_S_ERROR = 'Ebuild has redundant cd ${S} statement on line: %d'
EMAKE_PARALLEL_DISABLED = 'Upstream parallel compilation bug (ebuild calls emake -j1 on line: %d)'
DEPRECATED_BINDNOW_FLAGS = 'Deprecated bindnow-flags call on line: %d'
+PREPALLDOCS_ERROR = 'prepalldocs called on line: %d'