From 19c9c011200e0a60d29fddbeb211775b6549214c Mon Sep 17 00:00:00 2001 From: Will Fancher Date: Fri, 26 Sep 2025 02:44:26 -0400 Subject: [PATCH] rsync: Remove `fakeroot` from `checkInputs` MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Having `fakeroot` in `checkInputs` has the unfortunate side effect of making rsync depend on systemd, and by extension making the linux kernel depend on systemd. ``` $ nix why-depends --derivation --all -f . linux systemd.src /nix/store/ahnjzvyxn3jqaaqmhkrdxfimzd8m6yya-linux-6.12.48.drv └───/nix/store/07v98114pg0v4vb8xahdj6v488piy23r-rsync-3.4.1.drv └───/nix/store/70yyn9xwg3gkmdw7azal22wb8hp2lyxz-fakeroot-1.37.1.2.drv └───/nix/store/sac9bwghprnv77v8c65ljrwpr09c2wbi-libcap-2.76.drv └───/nix/store/9v3wirxpv9dzjkpr2swkgfwi78q0d72d-linux-pam-1.7.1.drv └───/nix/store/gfkzz6c2lhr73habq4x9ci7bj6jfgjgz-systemd-minimal-libs-257.9.drv └───/nix/store/kxpjbfihhzkm2dilaj4xxndxfwmbm98z-source.drv ``` My main goal is keep systemd updates from rebuilding the kernel, and admittedly the use of rsync in the kernel derivation is completely unnecessary. But I think, in its own right, removing the dependency of rsync on systemd is worthwhile. The consequence of this is that we have to skip two additional tests (out of the total of 46), namely the `chown` and `devices` tests. --- pkgs/applications/networking/sync/rsync/default.nix | 4 ---- 1 file changed, 4 deletions(-) diff --git a/pkgs/applications/networking/sync/rsync/default.nix b/pkgs/applications/networking/sync/rsync/default.nix index c38d5913d2ea..4dccabbf7fbf 100644 --- a/pkgs/applications/networking/sync/rsync/default.nix +++ b/pkgs/applications/networking/sync/rsync/default.nix @@ -19,7 +19,6 @@ enableZstd ? true, zstd, nixosTests, - fakeroot, }: stdenv.mkDerivation rec { @@ -58,9 +57,6 @@ stdenv.mkDerivation rec { ++ lib.optional enableOpenSSL openssl ++ lib.optional enableXXHash xxHash; - # fakeroot doesn't work well on darwin anymore, apparently - checkInputs = lib.optionals (!stdenv.isDarwin) [ fakeroot ]; - configureFlags = [ (lib.enableFeature enableLZ4 "lz4") (lib.enableFeature enableOpenSSL "openssl")