Load devtool and reciptool plugins in a well-defined manner
Get series with b4
b4 am [email protected]Versions newest first
- v1 Latest4 patches 3 repliesIn review
Patches in v1 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/4 | devtool: selftest: add test for devtool plugin loadingmeta-selftest/ meta/ | +87 | 0 replies | |
| 2/4 | recipetool: selftest: Add test for recipetool plugin loadingmeta-selftest/ meta/ | +85 | 0 replies | |
| 3/4 | devtool: Load plugins in a well defined orderscripts/ scripts/ | +8 | 0 replies | |
| 4/4 | recipetool: Load plugins in a well defined orderscripts/ | +2 | 0 replies |
Reviews trailers per patch
None of the 4 patches has a Reviewed-by or Acked-by of their own; the series has one for all of them.
| Patch | Paul Eggleton |
|---|---|
| Series | A-b |
| 1/4 | |
| 2/4 | |
| 3/4 | |
| 4/4 |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [PATCH 0/4] Load devtool and reciptool plugins in a well-defined manner
From: Ola x Nilsson <[email protected]>
Make devtool and recipetool load plugins in a well-defined and expected manner.
devtool and reciptool search for pluings first in scripts/lib/<tool> and then in BBPATH. Each found plugin is loaded, which means that any plugin found later in BBPATH shadows previously loaded plugins. plugin_init is loaded for all plugins, no matter whether they are later replaced. register_plugin is called once for each time a plugin with a certain name is found, but it is always called on the last loaded plugin.
Change the scriptutils.load_plugins function to never load a plugin file if one with the same filename has already been loaded. This means that the first found plugin wins.
Change the load order to first search BBPATH and then scripts/lib/tools. This means that plugins in scripts/lib/<tool> can be shadowed by plugins in layers.
Ola x Nilsson (4):
devtool: selftest: add test for devtool plugin loading
recipetool: selftest: Add test for recipetool plugin loading
devtool: Load plugins in a well defined order
recipetool: Load plugins in a well defined order
meta-selftest/lib/devtool/bbpath.py | 44 ++++++++++++++++++++++++++++++++++ meta-selftest/lib/recipetool/bbpath.py | 41 +++++++++++++++++++++++++++++++ meta/lib/oeqa/selftest/devtool.py | 43 +++++++++++++++++++++++++++++++++ meta/lib/oeqa/selftest/recipetool.py | 44 ++++++++++++++++++++++++++++++++++ scripts/devtool | 3 ++- scripts/lib/scriptutils.py | 8 +++++-- scripts/recipetool | 4 ++-- 7 files changed, 182 insertions(+), 5 deletions(-) create mode 100644 meta-selftest/lib/devtool/bbpath.py create mode 100644 meta-selftest/lib/recipetool/bbpath.py
Signature · 1 line
2.1.4