diff --git a/pkgs/tools/filesystems/squashfs/default.nix b/pkgs/tools/filesystems/squashfs/default.nix index 340c5add295e..3be3865ccd07 100644 --- a/pkgs/tools/filesystems/squashfs/default.nix +++ b/pkgs/tools/filesystems/squashfs/default.nix @@ -24,12 +24,21 @@ stdenv.mkDerivation rec { }; patches = [ + # remove once https://github.com/plougher/squashfs-tools/pull/177 is merged and in a release + (fetchpatch { + url = "https://github.com/plougher/squashfs-tools/commit/6100e82c7e7f18f503c003c67c87791025d5f01b.patch"; + sha256 = "sha256-bMBQsbSKQ4E7r9avns2QaomGAYl3s82m58gYyTQdB08="; + }) # This patch adds an option to pad filesystems (increasing size) in # exchange for better chunking / binary diff calculation. ./4k-align.patch ] ++ lib.optional stdenv.isDarwin ./darwin.patch; - buildInputs = [ zlib xz zstd lz4 lzo which help2man ]; + strictDeps = true; + nativeBuildInputs = [ which ] + # when cross-compiling help2man cannot run the cross-compiled binary + ++ lib.optionals (stdenv.hostPlatform == stdenv.buildPlatform) [ help2man ]; + buildInputs = [ zlib xz zstd lz4 lzo ]; preBuild = '' cd squashfs-tools