diff options
author | Tom Zanussi <tom.zanussi@linux.intel.com> | 2014-07-04 19:21:29 -0500 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2014-07-10 17:38:34 +0100 |
commit | b5dceca4369ef2ae0825d5298aa640b68d7d7da1 (patch) | |
tree | 27ae76c5f27b0f8adc8a45d24dffded383c95fe0 /scripts | |
parent | 1908751b3283d7e14d3a9f68b0926a384cafe9ca (diff) | |
download | poky-b5dceca4369ef2ae0825d5298aa640b68d7d7da1.tar.gz |
wic: Print error if a partition specifies an invalid --source
If a partition specified in a .wks file specifies a nonexistent
--source, print an error to that effect and exit. The error text also
points the user to a command listing valid sources, and help on adding
a new source plugin.
(From OE-Core rev: 4dff6945d2606cebc0ab26e877c5d8c7b457e179)
Signed-off-by: Tom Zanussi <tom.zanussi@linux.intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'scripts')
-rw-r--r-- | scripts/lib/mic/kickstart/custom_commands/partition.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/scripts/lib/mic/kickstart/custom_commands/partition.py b/scripts/lib/mic/kickstart/custom_commands/partition.py index 6b575c0e8d..75ad6ad103 100644 --- a/scripts/lib/mic/kickstart/custom_commands/partition.py +++ b/scripts/lib/mic/kickstart/custom_commands/partition.py | |||
@@ -130,6 +130,11 @@ class Wic_PartData(Mic_PartData): | |||
130 | native_sysroot) | 130 | native_sysroot) |
131 | return | 131 | return |
132 | 132 | ||
133 | plugins = pluginmgr.get_source_plugins() | ||
134 | |||
135 | if self.source not in plugins: | ||
136 | msger.error("The '%s' --source specified for %s doesn't exist.\n\tSee 'wic list source-plugins' for a list of available --sources.\n\tSee 'wic help source-plugins' for details on adding a new source plugin." % (self.source, self.mountpoint)) | ||
137 | |||
133 | self._source_methods = pluginmgr.get_source_plugin_methods(self.source, partition_methods) | 138 | self._source_methods = pluginmgr.get_source_plugin_methods(self.source, partition_methods) |
134 | self._source_methods["do_configure_partition"](self, cr, cr_workdir, | 139 | self._source_methods["do_configure_partition"](self, cr, cr_workdir, |
135 | oe_builddir, | 140 | oe_builddir, |