diff options
author | Naveen Saini <naveen.kumar.saini@intel.com> | 2020-08-21 09:00:36 +0800 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2020-08-27 08:28:03 +0100 |
commit | 3204982fd7b605ca12307d0718e6617d38d5d577 (patch) | |
tree | 9bbd0148cd957d311f3ca42eec299eabc5c53ac7 /meta/lib/oe | |
parent | 15c61b684c200b96b5ae0dcf732d71a2c7345e30 (diff) | |
download | poky-3204982fd7b605ca12307d0718e6617d38d5d577.tar.gz |
lib/oe/recipeutils.py: add support for BBFILES_DYNAMIC
Instead of relying on value of BBFILES from bitbake, devtool
parses the layer.conf because the layer might not be in bblayers.conf.
And it currently does not consider the value of BBFILES_DYNAMIC because
of which recipes, in paths defined by BBFILES_DYNAMIC, upgraded
using devtool end up in wrong location.
Include the code from bitbake to append values to BBFILES based on
what is in BBFILES_DYNAMIC too.
(From OE-Core rev: c7bbb98ea8ccd3568dd8bded6e404e2f781e6841)
Signed-off-by: Naveen Saini <naveen.kumar.saini@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/lib/oe')
-rw-r--r-- | meta/lib/oe/recipeutils.py | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/meta/lib/oe/recipeutils.py b/meta/lib/oe/recipeutils.py index 36427eec91..ef69ef207f 100644 --- a/meta/lib/oe/recipeutils.py +++ b/meta/lib/oe/recipeutils.py | |||
@@ -563,6 +563,23 @@ def get_bbfile_path(d, destdir, extrapathhint=None): | |||
563 | confdata = bb.cookerdata.parse_config_file(destlayerconf, confdata) | 563 | confdata = bb.cookerdata.parse_config_file(destlayerconf, confdata) |
564 | pn = d.getVar('PN') | 564 | pn = d.getVar('PN') |
565 | 565 | ||
566 | # Parse BBFILES_DYNAMIC and append to BBFILES | ||
567 | bbfiles_dynamic = (confdata.getVar('BBFILES_DYNAMIC') or "").split() | ||
568 | collections = (confdata.getVar('BBFILE_COLLECTIONS') or "").split() | ||
569 | invalid = [] | ||
570 | for entry in bbfiles_dynamic: | ||
571 | parts = entry.split(":", 1) | ||
572 | if len(parts) != 2: | ||
573 | invalid.append(entry) | ||
574 | continue | ||
575 | l, f = parts | ||
576 | invert = l[0] == "!" | ||
577 | if invert: | ||
578 | l = l[1:] | ||
579 | if (l in collections and not invert) or (l not in collections and invert): | ||
580 | confdata.appendVar("BBFILES", " " + f) | ||
581 | if invalid: | ||
582 | return None | ||
566 | bbfilespecs = (confdata.getVar('BBFILES') or '').split() | 583 | bbfilespecs = (confdata.getVar('BBFILES') or '').split() |
567 | if destdir == destlayerdir: | 584 | if destdir == destlayerdir: |
568 | for bbfilespec in bbfilespecs: | 585 | for bbfilespec in bbfilespecs: |