mbox series

[0/2] image_types_wic: fix dependencies on wks files

Message ID 20250520075325.64756-1-fhoerni.opensource@witekio.com
Headers show
Series image_types_wic: fix dependencies on wks files | expand

Message

fhoerni.opensource@witekio.com May 20, 2025, 7:53 a.m. UTC
From: Frederic Hoerni <fhoerni@witekio.com>

This series of patches is meant to raise an issue about missing dependencies on
wks(.in) files in WKS_SEARCH_PATH, and proposes a technical solution.

The issue is that adding a wks file earlier in the search path is not taken
into account automatically. See the message of the second patch to get a
detailed procedure for reproducing the issue.

I propose here to define a lib function 'search_file', that is used by
image_types_wic.bbclass but can also be used by other custom recipes.
This lib function is in meta/lib/oe/searchfile.py. Please confirm if
this is a relevant and consistent place, or if it should be grouped with
some other existing file.

In meta/lib/oe/searchfile.py, I wrote the docstring using the same formalism as
in bitbake/lib/bb/utils.py (command 'which'), but I am not sure if this is
relevant and if this formalism is actually used somewhere (especially the
double-backticks).

That being said, there are still missing dependencies on files included from the
main wks file, not resolved by these patches.

Frederic Hoerni (2):
  meta/lib/oe: add searchfile.py
  image_types_wic: fix dependencies on wks files

 meta/classes-recipe/image_types_wic.bbclass | 18 +++-------
 meta/lib/oe/searchfile.py                   | 37 +++++++++++++++++++++
 2 files changed, 41 insertions(+), 14 deletions(-)
 create mode 100644 meta/lib/oe/searchfile.py