From f4b2c9dfe7cb63edc8059c6caeaa9de015068628 Mon Sep 17 00:00:00 2001 From: Anders Kaseorg Date: Thu, 3 Sep 2020 04:51:36 -0700 Subject: cryptsetup, lvm2, systemd: Break cyclic dependency at a different point MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The cyclic dependency of systemd → cryptsetup → lvm2 → udev=systemd needs to be broken somewhere. The previous strategy of building cryptsetup with an lvm2 built without udev (#66856) caused the installer.luksroot test to fail. Instead, build lvm2 with a udev built without cryptsetup. Fixes #96479. Signed-off-by: Anders Kaseorg --- pkgs/top-level/all-packages.nix | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) (limited to 'pkgs') diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index dffd32e9bc3a5..879fd4bd832b1 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -17246,11 +17246,7 @@ in criu = callPackage ../os-specific/linux/criu { }; - cryptsetup = callPackage ../os-specific/linux/cryptsetup { - # cryptsetup only really needs the devmapper component of cryptsetup - # but itself is used as a library in systemd (=udev) - lvm2 = lvm2.override { udev = null; }; - }; + cryptsetup = callPackage ../os-specific/linux/cryptsetup { }; cramfsprogs = callPackage ../os-specific/linux/cramfsprogs { }; @@ -18032,7 +18028,12 @@ in lsscsi = callPackage ../os-specific/linux/lsscsi { }; - lvm2 = callPackage ../os-specific/linux/lvm2 { }; + lvm2 = callPackage ../os-specific/linux/lvm2 { + # udev is the same package as systemd which depends on cryptsetup + # which depends on lvm2 again. But we only need the libudev part + # which does not depend on cryptsetup. + udev = udev.override { cryptsetup = null; }; + }; lvm2_dmeventd = callPackage ../os-specific/linux/lvm2 { enableDmeventd = true; enableCmdlib = true; -- cgit 1.4.1