Skip to content

Commit

Permalink
feat: revert compression tweaks
Browse files Browse the repository at this point in the history
  • Loading branch information
madonuko committed Sep 28, 2024
1 parent 7668c19 commit be5c3c2
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions src/builder.rs
Original file line number Diff line number Diff line change
Expand Up @@ -554,7 +554,7 @@ pub struct IsoBuilder {

const DR_MODS: &str = "livenet dmsquash-live dmsquash-live-ntfs convertfs pollcdrom qemu qemu-net";
const DR_OMIT: &str = "";
const DR_ARGS: &str = "--xz --no-early-microcode --strip --aggressive-strip";
const DR_ARGS: &str = "--xz --no-early-microcode";

impl IsoBuilder {
fn dracut(&self, root: &Path) -> Result<()> {
Expand Down Expand Up @@ -603,9 +603,6 @@ impl IsoBuilder {
dr_args.push(&dr_omit);
}

if std::env::var("INITRD_COMPRESS").is_err() {
std::env::set_var("INITRD_COMPRESS", "zstd --ultra -22 -q -T0");
}
crate::chroot_run_cmd!(root,
unshare -R $root env - DRACUT_SYSTEMD=0 dracut $[dr_args]
/boot/initramfs-$kver.img --kver $kver 2>&1;
Expand All @@ -626,7 +623,7 @@ impl IsoBuilder {
"lzo" => "-comp lzo",
"lz4" => "-comp lz4 -Xhc",
"xz" => "-comp xz -Xbcj x86",
"zstd" => "-comp zstd -Xcompression-level 22",
"zstd" => "-comp zstd -Xcompression-level 19",
"lzma" => "-comp lzma",
_ => bail!("Unknown squashfs compression: {sqfs_comp}"),
}
Expand Down

0 comments on commit be5c3c2

Please sign in to comment.