mirror of
https://git.yoctoproject.org/poky
synced 2026-05-01 15:32:12 +02:00
wic: Remove special-case bootimg_dir
The first iterations of wic very shortsightedly catered to two specific use-cases and added special-purpose params for those cases so that they could be directly given their corresponding boot artifacts. (hdddir and staging_data_dir). As more use-cases are added, it becomes rather obvious that such a scheme doens't scale, and additionally causes confusion for plugin writers. This removes those special cases and states explicitly in the help text that plugins are responsible for locating their own boot artifacts. (From OE-Core rev: 6ba3eb5ff7c47aee6b3419fb3a348a634fe74ac9) Signed-off-by: Tom Zanussi <tom.zanussi@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
committed by
Richard Purdie
parent
38400617fe
commit
42d0334aa8
@@ -173,7 +173,6 @@ class BootimgEFIPlugin(SourcePlugin):
|
||||
cr.set_bootimg_dir(bootimg_dir)
|
||||
|
||||
staging_kernel_dir = kernel_dir
|
||||
staging_data_dir = bootimg_dir
|
||||
|
||||
hdddir = "%s/hdd/boot" % cr_workdir
|
||||
|
||||
@@ -185,12 +184,12 @@ class BootimgEFIPlugin(SourcePlugin):
|
||||
if source_params['loader'] == 'grub-efi':
|
||||
shutil.copyfile("%s/hdd/boot/EFI/BOOT/grub.cfg" % cr_workdir,
|
||||
"%s/grub.cfg" % cr_workdir)
|
||||
cp_cmd = "cp %s/EFI/BOOT/* %s/EFI/BOOT" % (staging_data_dir, hdddir)
|
||||
cp_cmd = "cp %s/EFI/BOOT/* %s/EFI/BOOT" % (bootimg_dir, hdddir)
|
||||
exec_cmd(cp_cmd, True)
|
||||
shutil.move("%s/grub.cfg" % cr_workdir,
|
||||
"%s/hdd/boot/EFI/BOOT/grub.cfg" % cr_workdir)
|
||||
elif source_params['loader'] == 'gummiboot':
|
||||
cp_cmd = "cp %s/EFI/BOOT/* %s/EFI/BOOT" % (staging_data_dir, hdddir)
|
||||
cp_cmd = "cp %s/EFI/BOOT/* %s/EFI/BOOT" % (bootimg_dir, hdddir)
|
||||
exec_cmd(cp_cmd, True)
|
||||
else:
|
||||
msger.error("unrecognized bootimg-efi loader: %s" % source_params['loader'])
|
||||
|
||||
@@ -144,7 +144,6 @@ class BootimgPcbiosPlugin(SourcePlugin):
|
||||
cr.set_bootimg_dir(bootimg_dir)
|
||||
|
||||
staging_kernel_dir = kernel_dir
|
||||
staging_data_dir = bootimg_dir
|
||||
|
||||
hdddir = "%s/hdd/boot" % cr_workdir
|
||||
|
||||
@@ -153,7 +152,7 @@ class BootimgPcbiosPlugin(SourcePlugin):
|
||||
exec_cmd(install_cmd)
|
||||
|
||||
install_cmd = "install -m 444 %s/syslinux/ldlinux.sys %s/ldlinux.sys" \
|
||||
% (staging_data_dir, hdddir)
|
||||
% (bootimg_dir, hdddir)
|
||||
exec_cmd(install_cmd)
|
||||
|
||||
du_cmd = "du -bks %s" % hdddir
|
||||
|
||||
Reference in New Issue
Block a user