libvirt: fix install error without qemu
PATCH 1/1 libvirt: fix install error without qemu
An error occurs during the install step of libvirt when the variable PACKAGECONFIG does not contain qemu.
Indeed, in this case, the operation "chown -R qemu:qemu ${D}/${localstatedir}/lib/libvirt/qemu" fails, since the folder ${D}/${localstatedir}/lib/libvirt/qemu has not been created.
The fix consist in doing this operation only if the variable “PACKAGECONFIG” contains “qemu”.
remark: issue present since the Warrior release of yocto.
Upstream-Status: Pending
--- recipes-extended/libvirt/libvirt_6.1.0.bb | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-)
recipes-extended/libvirt/libvirt_6.1.0.bb +6 -4
@@ -340,10 +340,12 @@ do_install_append() { break ;; *) - chown -R qemu:qemu ${D}/${localstatedir}/lib/libvirt/qemu - echo "d qemu qemu 0755 ${localstatedir}/cache/libvirt/qemu none" \ - >> ${D}${sysconfdir}/default/volatiles/99_libvirt - break + if ${@bb.utils.contains('PACKAGECONFIG', 'qemu', 'true', 'false', d)}; then + chown -R qemu:qemu ${D}/${localstatedir}/lib/libvirt/qemu + echo "d qemu qemu 0755 ${localstatedir}/cache/libvirt/qemu none" \ + >> ${D}${sysconfdir}/default/volatiles/99_libvirt + break + fi ;; esac
--
2.18.0.129.ge333175
Quoted 11 lines · Nicolas
An error occurs during the install step of libvirt when the variable PACKAGECONFIG does not contain qemu.
Indeed, in this case, the operation "chown -R qemu:qemu ${D}/${localstatedir}/lib/libvirt/qemu" fails, since the folder ${D}/${localstatedir}/lib/libvirt/qemu has not been created.
The fix consist in doing this operation only if the variable “PACKAGECONFIG” contains “qemu”.
remark: issue present since the Warrior release of yocto.
Technically this patch needs to be against master, not an older branch. Changes merge to master first, and then we backport appropriately.
But the patch edit was trivial in this case, so I fixed it for master and have now pushed it for master and dunfell.
Bruce
Quoted 42 lines
Upstream-Status: Pending
Signed-off-by Nicolas Lavocat <[email protected]>--- recipes-extended/libvirt/libvirt_6.1.0.bb | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-)recipes-extended/libvirt/libvirt_6.1.0.bb +0
-1@@ -340,10 +340,12 @@ do_install_append() { break ;; *) - chown -R qemu:qemu${D}/${localstatedir}/lib/libvirt/qemu
- echo "d qemu qemu 0755
${localstatedir}/cache/libvirt/qemu none" \
- >>
${D}${sysconfdir}/default/volatiles/99_libvirtrecipes-extended/libvirt/libvirt_6.1.0.bb +1
-1- break + if ${@bb.utils.contains('PACKAGECONFIG', 'qemu','true', 'false', d)}; then
+ chown -R qemu:qemu
${D}/${localstatedir}/lib/libvirt/qemu
+ echo "d qemu qemu 0755
${localstatedir}/cache/libvirt/qemu none" \
+ >>
${D}${sysconfdir}/default/volatiles/99_libvirtrecipes-extended/libvirt/libvirt_6.1.0.bb +2
-1+ break + fi ;; esac --2.18.0.129.ge333175
Signature · 3 lines
- Thou shalt not follow the NULL pointer, for chaos and madness await thee at its end - "Use the force Harry" - Gandalf, Star Trek II