mirror of
https://git.yoctoproject.org/poky
synced 2026-06-01 00:59:48 +00:00
wic: direct: set bootloader.source in the __init__
Moved setting of bootloader source from do_create method to __init__ as it doesn't have anything to do with image creation. (From OE-Core rev: 361b890da1c7b24de0a62516545e4c164830081d) Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
committed by
Richard Purdie
parent
58528cd5a7
commit
01d37e7537
@@ -87,6 +87,13 @@ class DirectPlugin(ImagerPlugin):
|
|||||||
continue
|
continue
|
||||||
part.realnum = realnum
|
part.realnum = realnum
|
||||||
|
|
||||||
|
# as a convenience, set source to the boot partition source
|
||||||
|
# instead of forcing it to be set via bootloader --source
|
||||||
|
for part in self.parts:
|
||||||
|
if not self.ks.bootloader.source and part.mountpoint == "/boot":
|
||||||
|
self.ks.bootloader.source = part.source
|
||||||
|
break
|
||||||
|
|
||||||
def do_create(self):
|
def do_create(self):
|
||||||
"""
|
"""
|
||||||
Plugin entry point.
|
Plugin entry point.
|
||||||
@@ -160,12 +167,6 @@ class DirectPlugin(ImagerPlugin):
|
|||||||
self._image = PartitionedImage(image_path, self.ptable_format,
|
self._image = PartitionedImage(image_path, self.ptable_format,
|
||||||
self.parts, self.native_sysroot)
|
self.parts, self.native_sysroot)
|
||||||
|
|
||||||
for part in self.parts:
|
|
||||||
# as a convenience, set source to the boot partition source
|
|
||||||
# instead of forcing it to be set via bootloader --source
|
|
||||||
if not self.ks.bootloader.source and part.mountpoint == "/boot":
|
|
||||||
self.ks.bootloader.source = part.source
|
|
||||||
|
|
||||||
fstab_path = self._write_fstab(self.rootfs_dir.get("ROOTFS_DIR"))
|
fstab_path = self._write_fstab(self.rootfs_dir.get("ROOTFS_DIR"))
|
||||||
|
|
||||||
for part in self.parts:
|
for part in self.parts:
|
||||||
|
|||||||
Reference in New Issue
Block a user