From 8ebd3c038979180ad64389bc1b94a7dea6186e25 Mon Sep 17 00:00:00 2001 From: Artturin Date: Tue, 26 Apr 2022 17:53:32 +0300 Subject: [PATCH 1/3] squashfsTools: enable strictDeps --- pkgs/tools/filesystems/squashfs/default.nix | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/pkgs/tools/filesystems/squashfs/default.nix b/pkgs/tools/filesystems/squashfs/default.nix index 340c5add295e..914d4aa33c2c 100644 --- a/pkgs/tools/filesystems/squashfs/default.nix +++ b/pkgs/tools/filesystems/squashfs/default.nix @@ -29,7 +29,9 @@ stdenv.mkDerivation rec { ./4k-align.patch ] ++ lib.optional stdenv.isDarwin ./darwin.patch; - buildInputs = [ zlib xz zstd lz4 lzo which help2man ]; + strictDeps = true; + nativeBuildInputs = [ help2man which ]; + buildInputs = [ zlib xz zstd lz4 lzo ]; preBuild = '' cd squashfs-tools From 7ed2f7d1ba20604621271c229ff499c05621e7b8 Mon Sep 17 00:00:00 2001 From: Artturin Date: Tue, 26 Apr 2022 17:55:29 +0300 Subject: [PATCH 2/3] squashfsTools: pull patch to make manpages reproducible adds -n to gzip --- pkgs/tools/filesystems/squashfs/default.nix | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/pkgs/tools/filesystems/squashfs/default.nix b/pkgs/tools/filesystems/squashfs/default.nix index 914d4aa33c2c..0b2d6ae9cd65 100644 --- a/pkgs/tools/filesystems/squashfs/default.nix +++ b/pkgs/tools/filesystems/squashfs/default.nix @@ -24,6 +24,11 @@ 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 From 4f653a68d8b676931fabeab4b8eec2dcb9c1e5af Mon Sep 17 00:00:00 2001 From: Artturin Date: Tue, 26 Apr 2022 20:42:33 +0300 Subject: [PATCH 3/3] squafsTools: fix cross --- pkgs/tools/filesystems/squashfs/default.nix | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/pkgs/tools/filesystems/squashfs/default.nix b/pkgs/tools/filesystems/squashfs/default.nix index 0b2d6ae9cd65..3be3865ccd07 100644 --- a/pkgs/tools/filesystems/squashfs/default.nix +++ b/pkgs/tools/filesystems/squashfs/default.nix @@ -35,7 +35,9 @@ stdenv.mkDerivation rec { ] ++ lib.optional stdenv.isDarwin ./darwin.patch; strictDeps = true; - nativeBuildInputs = [ help2man which ]; + 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 = ''