summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlexander Kanavin <alex.kanavin@gmail.com>2020-01-20 18:24:53 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2020-01-21 12:52:48 +0000
commit749f44b3735e4ae3657255b373fa55c357501cc5 (patch)
tree711f9a4b484b1e47c0b35604581a1c4b4341b0fb
parent07fce50afd219049046b9fc080304558c05e51bd (diff)
downloadopenembedded-core-contrib-749f44b3735e4ae3657255b373fa55c357501cc5.tar.gz
selftest: check maintainers.inc for entries without recipes
Also remove a couple of entries found by the test :) Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--meta/conf/distro/include/maintainers.inc6
-rw-r--r--meta/lib/oeqa/selftest/cases/distrodata.py34
2 files changed, 32 insertions, 8 deletions
diff --git a/meta/conf/distro/include/maintainers.inc b/meta/conf/distro/include/maintainers.inc
index ffb6da7dae..01afc25b93 100644
--- a/meta/conf/distro/include/maintainers.inc
+++ b/meta/conf/distro/include/maintainers.inc
@@ -183,7 +183,6 @@ RECIPE_MAINTAINER_pn-flex = "Chen Qi <Qi.Chen@windriver.com>"
RECIPE_MAINTAINER_pn-font-alias = "Armin Kuster <akuster808@gmail.com>"
RECIPE_MAINTAINER_pn-font-util = "Armin Kuster <akuster808@gmail.com>"
RECIPE_MAINTAINER_pn-fontconfig = "Ross Burton <ross.burton@intel.com>"
-RECIPE_MAINTAINER_pn-foomatic-filters = "Chen Qi <Qi.Chen@windriver.com>"
RECIPE_MAINTAINER_pn-formfactor = "Ross Burton <ross.burton@intel.com>"
RECIPE_MAINTAINER_pn-freetype = "Ross Burton <ross.burton@intel.com>"
RECIPE_MAINTAINER_pn-fribidi = "Ross Burton <ross.burton@intel.com>"
@@ -551,7 +550,6 @@ RECIPE_MAINTAINER_pn-pciutils = "Chen Qi <Qi.Chen@windriver.com>"
RECIPE_MAINTAINER_pn-pcmanfm = "Alexander Kanavin <alex.kanavin@gmail.com>"
RECIPE_MAINTAINER_pn-perf = "Bruce Ashfield <bruce.ashfield@gmail.com>"
RECIPE_MAINTAINER_pn-perl = "Alexander Kanavin <alex.kanavin@gmail.com>"
-RECIPE_MAINTAINER_pn-perl-native = "Alexander Kanavin <alex.kanavin@gmail.com>"
RECIPE_MAINTAINER_pn-piglit = "Ross Burton <ross.burton@intel.com>"
RECIPE_MAINTAINER_pn-pigz = "Hongxu Jia <hongxu.jia@windriver.com>"
RECIPE_MAINTAINER_pn-pinentry = "Armin Kuster <akuster808@gmail.com>"
@@ -574,9 +572,6 @@ RECIPE_MAINTAINER_pn-ptest-runner = "Ross Burton <ross.burton@intel.com>"
RECIPE_MAINTAINER_pn-pulseaudio = "Tanu Kaskinen <tanuk@iki.fi>"
RECIPE_MAINTAINER_pn-pulseaudio-client-conf-sato = "Tanu Kaskinen <tanuk@iki.fi>"
RECIPE_MAINTAINER_pn-puzzles = "Anuj Mittal <anuj.mittal@intel.com>"
-RECIPE_MAINTAINER_pn-python = "Oleksandr Kravchuk <open.source@oleksandr-kravchuk.com>"
-RECIPE_MAINTAINER_pn-python-native = "Oleksandr Kravchuk <open.source@oleksandr-kravchuk.com>"
-RECIPE_MAINTAINER_pn-python-setuptools = "Oleksandr Kravchuk <open.source@oleksandr-kravchuk.com>"
RECIPE_MAINTAINER_pn-python3 = "Oleksandr Kravchuk <open.source@oleksandr-kravchuk.com>"
RECIPE_MAINTAINER_pn-python3-async = "Oleksandr Kravchuk <open.source@oleksandr-kravchuk.com>"
RECIPE_MAINTAINER_pn-python3-dbus = "Oleksandr Kravchuk <open.source@oleksandr-kravchuk.com>"
@@ -586,7 +581,6 @@ RECIPE_MAINTAINER_pn-python3-git = "Oleksandr Kravchuk <open.source@oleksandr-kr
RECIPE_MAINTAINER_pn-python3-gitdb = "Oleksandr Kravchuk <open.source@oleksandr-kravchuk.com>"
RECIPE_MAINTAINER_pn-python3-iniparse = "Oleksandr Kravchuk <open.source@oleksandr-kravchuk.com>"
RECIPE_MAINTAINER_pn-python3-mako = "Oleksandr Kravchuk <open.source@oleksandr-kravchuk.com>"
-RECIPE_MAINTAINER_pn-python3-native = "Oleksandr Kravchuk <open.source@oleksandr-kravchuk.com>"
RECIPE_MAINTAINER_pn-python3-nose = "Oleksandr Kravchuk <open.source@oleksandr-kravchuk.com>"
RECIPE_MAINTAINER_pn-python3-numpy = "Oleksandr Kravchuk <open.source@oleksandr-kravchuk.com>"
RECIPE_MAINTAINER_pn-python3-pbr = "Oleksandr Kravchuk <open.source@oleksandr-kravchuk.com>"
diff --git a/meta/lib/oeqa/selftest/cases/distrodata.py b/meta/lib/oeqa/selftest/cases/distrodata.py
index 68ba556485..5f7f488349 100644
--- a/meta/lib/oeqa/selftest/cases/distrodata.py
+++ b/meta/lib/oeqa/selftest/cases/distrodata.py
@@ -42,8 +42,9 @@ but their recipes claim otherwise by setting UPSTREAM_VERSION_UNKNOWN. Please re
def test_maintainers(self):
"""
- Summary: Test that oe-core recipes have a maintainer
+ Summary: Test that oe-core recipes have a maintainer and entries in maintainers list have a recipe
Expected: All oe-core recipes (except a few special static/testing ones) should have a maintainer listed in maintainers.inc file.
+ Expected: All entries in maintainers list should have a recipe file that matches them
Product: oe-core
Author: Alexander Kanavin <alex.kanavin@gmail.com>
"""
@@ -54,7 +55,16 @@ but their recipes claim otherwise by setting UPSTREAM_VERSION_UNKNOWN. Please re
return True
return False
- feature = 'require conf/distro/include/maintainers.inc\n'
+ def is_maintainer_exception(entry):
+ exceptions = ["systemd", "musl", "libpam", "newlib", "linux-yocto", "opensbi", "linux-dummy",
+ "mesa-gl", "libgfortran", "volatile-binds", "libgloss", "bsd-headers",
+ "cve-update-db-native", "libssp-nonshared", "argp-standalone", "fts"]
+ for i in exceptions:
+ if i in entry:
+ return True
+ return False
+
+ feature = 'require conf/distro/include/maintainers.inc\nLICENSE_FLAGS_WHITELIST += " commercial"\n'
self.write_config(feature)
with bb.tinfoil.Tinfoil() as tinfoil:
@@ -62,6 +72,11 @@ but their recipes claim otherwise by setting UPSTREAM_VERSION_UNKNOWN. Please re
with_maintainer_list = []
no_maintainer_list = []
+
+ missing_recipes = []
+ recipes = []
+ prefix = "RECIPE_MAINTAINER_pn-"
+
# We could have used all_recipes() here, but this method will find
# every recipe if we ever move to setting RECIPE_MAINTAINER in recipe files
# instead of maintainers.inc
@@ -71,6 +86,7 @@ but their recipes claim otherwise by setting UPSTREAM_VERSION_UNKNOWN. Please re
continue
rd = tinfoil.parse_recipe_file(fn, appends=False)
pn = rd.getVar('PN')
+ recipes.append(pn)
if is_exception(pn):
continue
if rd.getVar('RECIPE_MAINTAINER'):
@@ -78,6 +94,15 @@ but their recipes claim otherwise by setting UPSTREAM_VERSION_UNKNOWN. Please re
else:
no_maintainer_list.append((pn, fn))
+ maintainers = tinfoil.config_data.keys()
+ for key in maintainers:
+ if key.startswith(prefix):
+ recipe = tinfoil.config_data.expand(key[len(prefix):])
+ if is_maintainer_exception(recipe):
+ continue
+ if recipe not in recipes:
+ missing_recipes.append(recipe)
+
if no_maintainer_list:
self.fail("""
The following recipes do not have a maintainer assigned to them. Please add an entry to meta/conf/distro/include/maintainers.inc file.
@@ -87,3 +112,8 @@ The following recipes do not have a maintainer assigned to them. Please add an e
self.fail("""
The list of oe-core recipes with maintainers is empty. This may indicate that the test has regressed and needs fixing.
""")
+
+ if missing_recipes:
+ self.fail("""
+Unable to find recipes for the following entries in maintainers.inc:
+""" + "\n".join(['%s' % i for i in missing_recipes]))