"inherit.autotools":"Ebuild inherits autotools but does not call eautomake, eautoconf or eautoreconf",
"inherit.deprecated":"Ebuild inherits a deprecated eclass",
"java.eclassesnotused":"With virtual/jdk in DEPEND you must inherit a java eclass",
+ "prefix.usedwithhelpers":"Ebuild uses ED or EPREFIX with helpers (doins)",
"wxwidgets.eclassnotused":"Ebuild DEPENDs on x11-libs/wxGTK without inheriting wxwidgets.eclass",
"KEYWORDS.dropped":"Ebuilds that appear to have dropped KEYWORDS for some arch",
"KEYWORDS.missing":"Ebuilds that have a missing or empty KEYWORDS variable",
elif self._inherit_prefix_re.search(line) is not None:
self._prefix_inherited = True
+class EprefixWithHelpers(LineCheck):
+ """ Check that ED, EROOT and EPREFIX aren't used with helpers (doins) """
+
+ repoman_check_name = 'prefix.usedwithhelpers'
+ re = re.compile(r'.*\b(dodir|dohard|exeinto|insinto|into)\s+"?\$\{?(ED|EROOT|EPREFIX)\}?.*')
+ error = errors.EPREFIX_WITH_HELPERS
+
class ImplicitRuntimeDeps(LineCheck):
"""
Detect the case where DEPEND is set and RDEPEND is unset in the ebuild,
ImplicitRuntimeDeps, InheritAutotools, InheritDeprecated, IUseUndefined,
EMakeParallelDisabled, EMakeParallelDisabledViaMAKEOPTS, NoAsNeeded,
DeprecatedBindnowFlags, SrcUnpackPatches, WantAutoDefaultValue,
- SrcCompileEconf, Eapi3DeprecatedFuncs,
+ SrcCompileEconf, Eapi3DeprecatedFuncs, EprefixWithHelpers,
Eapi4IncompatibleFuncs, Eapi4GoneVars, BuiltWithUse,
PreserveOldLib, SandboxAddpredict)))
PRESERVE_OLD_LIB = 'Upstream ABI change workaround on line: %d'
BUILT_WITH_USE = 'built_with_use on line: %d'
EPREFIXIFY_MISSING_INHERIT = "prefix.eclass is not inherited, but eprefixify is used on line: %d"
+EPREFIX_WITH_HELPERS = "Helper function is used with ED, EROOT or ERPREFIX on line :%d"
SANDBOX_ADDPREDICT = 'Ebuild calls addpredict on line: %d'