summaryrefslogtreecommitdiffstats
path: root/nixos/modules
diff options
context:
space:
mode:
authorKevin Cox <kevincox@kevincox.ca>2021-01-15 11:32:21 -0500
committerGitHub <noreply@github.com>2021-01-15 11:32:21 -0500
commitbb9601719890dc04241304bb1a5cf224683d5740 (patch)
treec6317356d3a24392463f6376fed6b3526bb8185e /nixos/modules
parent1497071f23170651328b4ab0071fcbf3dd6a69d9 (diff)
parent2fcab516c4cae0bc50455abd356f60e576fec5d9 (diff)
Merge pull request #108932 from Atemu/iso-image-compress-filter
iso-image: enable XZ compress filter
Diffstat (limited to 'nixos/modules')
-rw-r--r--nixos/modules/installer/cd-dvd/iso-image.nix7
1 files changed, 6 insertions, 1 deletions
diff --git a/nixos/modules/installer/cd-dvd/iso-image.nix b/nixos/modules/installer/cd-dvd/iso-image.nix
index 43d20a556f8d..1418420afcd9 100644
--- a/nixos/modules/installer/cd-dvd/iso-image.nix
+++ b/nixos/modules/installer/cd-dvd/iso-image.nix
@@ -425,7 +425,12 @@ in
};
isoImage.squashfsCompression = mkOption {
- default = "xz -Xdict-size 100%";
+ default = with pkgs.stdenv.targetPlatform; "xz -Xdict-size 100% "
+ + lib.optionalString (isx86_32 || isx86_64) "-Xbcj x86"
+ # Untested but should also reduce size for these platforms
+ + lib.optionalString (isAarch32 || isAarch64) "-Xbcj arm"
+ + lib.optionalString (isPowerPC) "-Xbcj powerpc"
+ + lib.optionalString (isSparc) "-Xbcj sparc";
description = ''
Compression settings to use for the squashfs nix store.
'';