libvirt: patch more binary paths in systemd units

/bin/kill is referred in many more unit files than just
libvirtd.service.
This commit is contained in:
Florian Klink 2022-04-08 12:10:44 +02:00
parent fe871db088
commit 22660f2e23

View file

@ -323,7 +323,9 @@ stdenv.mkDerivation rec {
gettext() { "${gettext}/bin/gettext" "$@"; }
'
'' + optionalString isLinux ''
substituteInPlace $out/lib/systemd/system/libvirtd.service --replace /bin/kill ${coreutils}/bin/kill
for f in $out/lib/systemd/system/*.service ; do
substituteInPlace $f --replace /bin/kill ${coreutils}/bin/kill
done
rm $out/lib/systemd/system/{virtlockd,virtlogd}.*
wrapProgram $out/sbin/libvirtd \
--prefix PATH : /run/libvirt/nix-emulators:${binPath}