mirror of
https://git.yoctoproject.org/poky
synced 2026-05-30 00:20:08 +00:00
base/insane: Check pkgs lics are subset of recipe lics only once
Move logic checking that all packages licenses are only a subset of recipe licenses from base.bbclass to the insane.bbclass so that it's evaluated only once, during do_package_qa. As explained in the linked bugzilla entry, if a package license is not part of the recipe license, the warning message gets shown an unreasonable amount of time because it's evaluated every time a recipe is parsed. [YOCTO #10130] This also makes it possible to silence this error with INSANE_SKIP. (From OE-Core rev: 852408ed4be1f64c57e196688728b7ed223d3493) Signed-off-by: Quentin Schulz <quentin.schulz@streamunlimited.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
committed by
Richard Purdie
parent
6cb7107d86
commit
fa7b29e22b
@@ -584,19 +584,6 @@ python () {
|
||||
bb.debug(1, "Skipping recipe %s because of incompatible license(s): %s" % (pn, ' '.join(incompatible_lic)))
|
||||
raise bb.parse.SkipRecipe("it has incompatible license(s): %s" % ' '.join(incompatible_lic))
|
||||
|
||||
# Try to verify per-package (LICENSE_<pkg>) values. LICENSE should be a
|
||||
# superset of all per-package licenses. We do not do advanced (pattern)
|
||||
# matching of license expressions - just check that all license strings
|
||||
# in LICENSE_<pkg> are found in LICENSE.
|
||||
license_set = oe.license.list_licenses(license)
|
||||
for pkg in d.getVar('PACKAGES').split():
|
||||
pkg_license = d.getVar('LICENSE_' + pkg)
|
||||
if pkg_license:
|
||||
unlisted = oe.license.list_licenses(pkg_license) - license_set
|
||||
if unlisted:
|
||||
bb.warn("LICENSE_%s includes licenses (%s) that are not "
|
||||
"listed in LICENSE" % (pkg, ' '.join(unlisted)))
|
||||
|
||||
needsrcrev = False
|
||||
srcuri = d.getVar('SRC_URI')
|
||||
for uri in srcuri.split():
|
||||
|
||||
Reference in New Issue
Block a user