Skip to contentSkip to conversation

lvm2: add --with-systemdsystemunitdir in configuration

PATCH New Andrei Kholodnyi 1 participant 1 message Sep 24, 2015

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 lvm2: add --with-systemdsystemunitdir in configuration

Otherwise sed command for blk-availability.service may fail. It will look for the service file in a wrong location

---
 meta-oe/recipes-support/lvm2/lvm2.inc | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
meta-oe/recipes-support/lvm2/lvm2.inc +2 -1
index cc70246..cd7f6fd 100644
@@ -27,6 +27,7 @@ EXTRA_OECONF = "--with-user= \
                 --enable-lvmetad \
                 --with-udev-prefix= \
                 --with-usrlibdir=${libdir} \
+                --with-systemdsystemunitdir=${systemd_system_unitdir} \
 "
 
 PACKAGECONFIG += "${@base_contains('DISTRO_FEATURES', 'selinux', 'selinux', '', d)}"
@@ -41,7 +42,7 @@ do_install_append() {
     sed -i -e 's:@libdir@:${libdir}:g' ${D}${sysconfdir}/lvm/lvm.conf
     if ${@base_contains('DISTRO_FEATURES','systemd','true','false',d)}; then
         oe_runmake 'DESTDIR=${D}' install install_systemd_units
-        sed -i -e 's:/usr/bin/true:${base_bindir}/true:g' ${D}${systemd_unitdir}/system/blk-availability.service
+        sed -i -e 's:/usr/bin/true:${base_bindir}/true:g' ${D}${systemd_system_unitdir}/blk-availability.service
     else
         oe_runmake 'DESTDIR=${D}' install install_initscripts
         mv ${D}${sysconfdir}/rc.d/init.d ${D}${sysconfdir}/init.d
Signature · 1 line
2.1.4