diff options
author | Bruce Ashfield <bruce.ashfield@gmail.com> | 2022-04-19 20:10:52 -0400 |
---|---|---|
committer | Bruce Ashfield <bruce.ashfield@gmail.com> | 2022-04-19 20:11:39 -0400 |
commit | 51e404af981ab18391ca44d121fba71946abcc17 (patch) | |
tree | fbc6ccc77ea3bcd7acfe97fba5752e892ce922f4 /recipes-extended/xen | |
parent | 1f9c37e1a67a269833605a083e26538b130e4d8e (diff) | |
download | meta-virtualization-51e404af981ab18391ca44d121fba71946abcc17.tar.gz |
xen-tools: remove unused systemd/sysvinit files
The commit [ xen: only package xencommon systemd components if systemd
is enabled] attempted to only package init.d scripts for non-systemd
systems (and vice-versa for unit files).
But the xen-tools builds installs the files uncondtionally, so we can
end up with unpackaged files in some configurations. We can test on
the init system and removed the unused versions of the init to avoid
both packging and runtime issues.
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
Diffstat (limited to 'recipes-extended/xen')
-rw-r--r-- | recipes-extended/xen/xen-tools.inc | 17 |
1 files changed, 14 insertions, 3 deletions
diff --git a/recipes-extended/xen/xen-tools.inc b/recipes-extended/xen/xen-tools.inc index 6bbc8cd8..27972c16 100644 --- a/recipes-extended/xen/xen-tools.inc +++ b/recipes-extended/xen/xen-tools.inc | |||
@@ -807,13 +807,24 @@ do_install() { | |||
807 | done | 807 | done |
808 | fi | 808 | fi |
809 | 809 | ||
810 | # fixup default path to qemu-system-i386 | ||
811 | sed -i 's#\(test -z "$QEMU_XEN" && QEMU_XEN=\).*$#\1"/usr/bin/qemu-system-i386"#' ${D}/etc/init.d/xencommons | ||
812 | |||
813 | if [ -e ${D}${systemd_unitdir}/system/xen-qemu-dom0-disk-backend.service ]; then | 810 | if [ -e ${D}${systemd_unitdir}/system/xen-qemu-dom0-disk-backend.service ]; then |
814 | sed -i 's#ExecStart=.*qemu-system-i386\(.*\)$#ExecStart=/usr/bin/qemu-system-i386\1#' \ | 811 | sed -i 's#ExecStart=.*qemu-system-i386\(.*\)$#ExecStart=/usr/bin/qemu-system-i386\1#' \ |
815 | ${D}${systemd_unitdir}/system/xen-qemu-dom0-disk-backend.service | 812 | ${D}${systemd_unitdir}/system/xen-qemu-dom0-disk-backend.service |
816 | fi | 813 | fi |
814 | |||
815 | if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}; then | ||
816 | rm -f ${D}/${sysconfdir}/init.d/xencommons | ||
817 | else | ||
818 | # fixup default path to qemu-system-i386 | ||
819 | sed -i 's#\(test -z "$QEMU_XEN" && QEMU_XEN=\).*$#\1"/usr/bin/qemu-system-i386"#' ${D}/etc/init.d/xencommons | ||
820 | |||
821 | # remove the uncondiontally installed systemd service files | ||
822 | rm -f ${D}/${systemd_unitdir}/system/xen-qemu-dom0-disk-backend.service | ||
823 | rm -f ${D}/${systemd_unitdir}/system/xenconsoled.service | ||
824 | rm -f ${D}/${systemd_unitdir}/system/xen-init-dom0.service | ||
825 | rm -f ${D}/${systemd_unitdir}/system/xenstored.service | ||
826 | rm -f ${D}/${systemd_unitdir}/system/var-lib-xenstored.mount | ||
827 | fi | ||
817 | } | 828 | } |
818 | 829 | ||
819 | pkg_postinst:${PN}-volatiles() { | 830 | pkg_postinst:${PN}-volatiles() { |