diff options
author | Michael Ho <Michael.Ho@bmw.de> | 2021-01-12 09:55:33 +0100 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2021-01-21 23:08:16 +0000 |
commit | 702a22732284406cd3158ded2abb15fd0a054149 (patch) | |
tree | 880300430e7ccba38c7ace995f6f98819bee2fae /meta/classes/license_image.bbclass | |
parent | 61890c0ae61efcdc1cb0c908b21f74817543b661 (diff) | |
download | poky-702a22732284406cd3158ded2abb15fd0a054149.tar.gz |
license_image.bbclass: fix missing recipeinfo on self
Resolve a build bug where image recipes with a do_deploy task will fail.
If the image recipe inheriting license_image.bbclass has a deploy task, then
the function get_deployed_dependencies will add itself to the list of recipes
to get license information for.
However, image recipes don't generally deploy license info so this results in
an error.
File: '/nvme/poky/meta/classes/license_image.bbclass', lineno: 192, function: license_deployed_manifest
...
Exception: FileNotFoundError: [Errno 2] No such file or directory: '/nvme/poky/build/tmp/deploy/licenses/core-image-minimal/recipeinfo'
Add a corner case to exclude the originating image recipe from the list of
dependencies to check.
(From OE-Core rev: 444118a185ff6cdd20ad0a10ffae7edfa9ab18c4)
Signed-off-by: Michael Ho <Michael.Ho@bmw.de>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
(cherry picked from commit 13fb39e49e55a0bc7c78b0bfdc372163b3f9e70a)
Signed-off-by: Steve Sakoman <steve@sakoman.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/classes/license_image.bbclass')
-rw-r--r-- | meta/classes/license_image.bbclass | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/meta/classes/license_image.bbclass b/meta/classes/license_image.bbclass index acd8126f68..a69cc5f065 100644 --- a/meta/classes/license_image.bbclass +++ b/meta/classes/license_image.bbclass | |||
@@ -209,9 +209,10 @@ def get_deployed_dependencies(d): | |||
209 | deploy = {} | 209 | deploy = {} |
210 | # Get all the dependencies for the current task (rootfs). | 210 | # Get all the dependencies for the current task (rootfs). |
211 | taskdata = d.getVar("BB_TASKDEPDATA", False) | 211 | taskdata = d.getVar("BB_TASKDEPDATA", False) |
212 | pn = d.getVar("PN", True) | ||
212 | depends = list(set([dep[0] for dep | 213 | depends = list(set([dep[0] for dep |
213 | in list(taskdata.values()) | 214 | in list(taskdata.values()) |
214 | if not dep[0].endswith("-native")])) | 215 | if not dep[0].endswith("-native") and not dep[0] == pn])) |
215 | 216 | ||
216 | # To verify what was deployed it checks the rootfs dependencies against | 217 | # To verify what was deployed it checks the rootfs dependencies against |
217 | # the SSTATE_MANIFESTS for "deploy" task. | 218 | # the SSTATE_MANIFESTS for "deploy" task. |