summaryrefslogtreecommitdiffstats
path: root/pym/repoman
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2012-05-08 23:38:47 -0700
committerZac Medico <zmedico@gentoo.org>2012-05-09 00:09:22 -0700
commit20817801dd4ef0117bcc7b33c90650da1e920385 (patch)
treec2e30f858b87e9d1504774a8e84791aff149453c /pym/repoman
parent476f99337da69662660bfe2a0406b9ac5b4678c4 (diff)
downloadportage-20817801dd4ef0117bcc7b33c90650da1e920385.tar.gz
portage-20817801dd4ef0117bcc7b33c90650da1e920385.tar.bz2
portage-20817801dd4ef0117bcc7b33c90650da1e920385.zip
Parse EAPI with pattern from PMS section 7.3.1.
This implements the specification that was approved in Gentoo's council meeting on May 8, 2012 (see bug #402167). The parse-eapi-ebuild-head FEATURES setting is now enabled by default, and causes non-conformant ebuilds to be treated as invalid. This behavior will soon become enabled unconditionally.
Diffstat (limited to 'pym/repoman')
-rw-r--r--pym/repoman/checks.py7
1 files changed, 3 insertions, 4 deletions
diff --git a/pym/repoman/checks.py b/pym/repoman/checks.py
index 733bbc3c1..77df603a2 100644
--- a/pym/repoman/checks.py
+++ b/pym/repoman/checks.py
@@ -8,6 +8,7 @@ and correctness of an ebuild."""
import re
import time
import repoman.errors as errors
+import portage
from portage.eapi import eapi_supports_prefix, eapi_has_implicit_rdepend, \
eapi_has_src_prepare_and_src_configure, eapi_has_dosed_dohard, \
eapi_exports_AA, eapi_exports_KV
@@ -284,14 +285,12 @@ class EbuildUselessCdS(LineCheck):
class EapiDefinition(LineCheck):
"""
- Check that EAPI assignment conforms to PMS section 8.3.1
+ Check that EAPI assignment conforms to PMS section 7.3.1
(first non-comment, non-blank line).
"""
repoman_check_name = 'EAPI.definition'
ignore_comment = True
-
- # This pattern is specified by PMS section 8.3.1.
- _eapi_re = re.compile(r"^[ \t]*EAPI=(['\"]?)([A-Za-z0-9+_.-]*)\1[ \t]*(#.*)?$")
+ _eapi_re = portage._pms_eapi_re
def new(self, pkg):
self._cached_eapi = pkg.metadata['EAPI']