lvm2: allow building with systemd = null

The closure still picks up systemd via udev, however, overriding with eudev is
necessary to avoid the reference.
This commit is contained in:
Joachim Fasting 2019-05-25 15:04:12 +02:00
parent 494d2deebf
commit 0489025cab
No known key found for this signature in database
GPG Key ID: 5C204DF675C90294
1 changed files with 4 additions and 4 deletions

View File

@ -34,11 +34,11 @@ stdenv.mkDerivation {
preConfigure =
''
substituteInPlace scripts/lvm2_activation_generator_systemd_red_hat.c \
--replace /usr/bin/udevadm ${systemd}/bin/udevadm
sed -i /DEFAULT_SYS_DIR/d Makefile.in
sed -i /DEFAULT_PROFILE_DIR/d conf/Makefile.in
'' + stdenv.lib.optionalString (systemd != null) ''
substituteInPlace scripts/lvm2_activation_generator_systemd_red_hat.c \
--replace /usr/bin/udevadm ${systemd}/bin/udevadm
'';
enableParallelBuilding = true;
@ -73,7 +73,7 @@ stdenv.mkDerivation {
''
substituteInPlace $out/lib/udev/rules.d/13-dm-disk.rules \
--replace $out/sbin/blkid ${utillinux}/sbin/blkid
'' + stdenv.lib.optionalString (systemd != null) ''
# Systemd stuff
mkdir -p $out/etc/systemd/system $out/lib/systemd/system-generators
cp scripts/blk_availability_systemd_red_hat.service $out/etc/systemd/system