Skip to content

Commit c0bf635

Browse files
committed
fixing install to looking into EFI subdir for payload
1 parent 6709ad9 commit c0bf635

File tree

1 file changed

+7
-6
lines changed

1 file changed

+7
-6
lines changed

src/efi.rs

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -405,12 +405,13 @@ impl Component for Efi {
405405
let payload_src_dir = ver_dir.sub_dir("EFI")?;
406406
let firmware_filetree =
407407
crate::filetree::FileTree::new_from_dir(&payload_src_dir)?;
408-
for file_path_str in firmware_filetree.children.keys() {
409-
let file_path = Path::new(file_path_str);
410-
if file_path != meta_path {
411-
ver_dir.copy_file_at(file_path, destd, file_path)?;
412-
}
413-
}
408+
// copy all by applying a diff with a empty filetree
409+
let empty_filetree = filetree::FileTree {
410+
children: Default::default(),
411+
};
412+
let diff = empty_filetree.diff(&firmware_filetree)?;
413+
filetree::apply_diff(&payload_src_dir, destd, &diff, None)
414+
.context("applying supplemental firmware")?;
414415

415416
found_firmware.insert(
416417
pkg_name.clone(),

0 commit comments

Comments
 (0)