public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] portage r11480 - main/trunk/pym/repoman
@ 2008-08-31  7:13 Zac Medico (zmedico)
  0 siblings, 0 replies; only message in thread
From: Zac Medico (zmedico) @ 2008-08-31  7:13 UTC (permalink / raw
  To: gentoo-commits

Author: zmedico
Date: 2008-08-31 07:13:54 +0000 (Sun, 31 Aug 2008)
New Revision: 11480

Modified:
   main/trunk/pym/repoman/checks.py
   main/trunk/pym/repoman/errors.py
Log:
Add a warning for emake -j1 calls which disable parallelization. Thanks to
Diego "Flameeyes" Petten?\195?\178 for the suggestion.


Modified: main/trunk/pym/repoman/checks.py
===================================================================
--- main/trunk/pym/repoman/checks.py	2008-08-30 21:43:52 UTC (rev 11479)
+++ main/trunk/pym/repoman/checks.py	2008-08-31 07:13:54 UTC (rev 11480)
@@ -268,12 +268,19 @@
 		if self._iuse_def is None:
 			yield 'IUSE is not defined'
 
+class EMakeParallelDisabled(LineCheck):
+	"""Check for emake -j1 calls which disable parallelization."""
+	repoman_check_name = 'ebuild.minorsyn'
+	re = re.compile(r'^\s*emake\s*-j\s*1\s')
+	error = errors.EMAKE_PARALLEL_DISABLED
+
 _constant_checks = tuple((c() for c in (
 	EbuildHeader, EbuildWhitespace, EbuildQuote,
 	EbuildAssignment, EbuildUselessDodoc,
 	EbuildUselessCdS, EbuildNestedDie,
 	EbuildPatches, EbuildQuotedA,
-	IUseUndefined, InheritAutotools)))
+	IUseUndefined, InheritAutotools,
+	EMakeParallelDisabled)))
 
 def run_checks(contents, pkg):
 	checks = _constant_checks

Modified: main/trunk/pym/repoman/errors.py
===================================================================
--- main/trunk/pym/repoman/errors.py	2008-08-30 21:43:52 UTC (rev 11479)
+++ main/trunk/pym/repoman/errors.py	2008-08-31 07:13:54 UTC (rev 11480)
@@ -13,3 +13,4 @@
 NESTED_DIE_ERROR = 'Ebuild calls die in a subshell on line: %d'
 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 = 'Ebuild calls emake -j1 on line: %d'




^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2008-08-31  7:13 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-08-31  7:13 [gentoo-commits] portage r11480 - main/trunk/pym/repoman Zac Medico (zmedico)

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox