From 7fdfb828fd7586a2e9b93b174e48246fc2a90f3e Mon Sep 17 00:00:00 2001 From: Alexander Kanavin Date: Thu, 3 Aug 2023 13:39:53 +0200 Subject: bitbake: bitbake-layers: initialize tinfoil before registering command line arguments Plugins may want to use it (e.g. the layers-setup plugin that would want to discover writer sub-plugins with it), and so it makes sense to make tinfoil available a bit eariler. (Bitbake rev: 41b6684489d0261753344956042be2cc4adb0159) Signed-off-by: Alexander Kanavin Signed-off-by: Richard Purdie (cherry picked from commit 2f6c7523a622f59ddf84a1a196927492bc5fa7a2) Signed-off-by: Jermain Horsman Signed-off-by: Richard Purdie Signed-off-by: Steve Sakoman --- bitbake/bin/bitbake-layers | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'bitbake') diff --git a/bitbake/bin/bitbake-layers b/bitbake/bin/bitbake-layers index 449434d468..d4b1d1aaf2 100755 --- a/bitbake/bin/bitbake-layers +++ b/bitbake/bin/bitbake-layers @@ -68,11 +68,11 @@ def main(): registered = False for plugin in plugins: + if hasattr(plugin, 'tinfoil_init'): + plugin.tinfoil_init(tinfoil) if hasattr(plugin, 'register_commands'): registered = True plugin.register_commands(subparsers) - if hasattr(plugin, 'tinfoil_init'): - plugin.tinfoil_init(tinfoil) if not registered: logger.error("No commands registered - missing plugins?") -- cgit v1.2.3-54-g00ecf