From 8eb7e66246cf7c72dc68862f1c287029080a2e8a Mon Sep 17 00:00:00 2001 From: Parthiban Nallathambi Date: Tue, 20 Feb 2018 16:49:27 +0100 Subject: wic: Add post operation hook for SourcePlugin do_post_partition hook is needed if some operations like security signing the parition needs to be done. source plugins can make use of this to implement post operatiosn in do_post_partition. do_post_partition is called after do_prepare_partition if present. (From OE-Core rev: 5055489b9ab3fda32a285d0d165d080d11a4d432) Signed-off-by: Parthiban Nallathambi Signed-off-by: Ross Burton Signed-off-by: Richard Purdie --- scripts/lib/wic/pluginbase.py | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'scripts/lib/wic/pluginbase.py') diff --git a/scripts/lib/wic/pluginbase.py b/scripts/lib/wic/pluginbase.py index c009820adc..686d2fee3b 100644 --- a/scripts/lib/wic/pluginbase.py +++ b/scripts/lib/wic/pluginbase.py @@ -137,3 +137,13 @@ class SourcePlugin(metaclass=PluginMeta): 'prepares' the partition to be incorporated into the image. """ logger.debug("SourcePlugin: do_prepare_partition: part: %s", part) + + @classmethod + def do_post_partition(cls, part, source_params, creator, cr_workdir, + oe_builddir, bootimg_dir, kernel_dir, rootfs_dir, + native_sysroot): + """ + Called after the partition is created. It is useful to add post + operations e.g. security signing the partition. + """ + logger.debug("SourcePlugin: do_post_partition: part: %s", part) -- cgit v1.2.3-54-g00ecf