SUMMARY = "virt-manager" DESCRIPTION = "virt-manager" HOMEPAGE = "http://virt-manager.org" SECTION = "devel" LICENSE = "GPLv2+" LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe" SRC_URI = "https://fedorahosted.org/released/virt-manager/virt-manager-${PV}.tar.gz" SRC_URI[sha256sum] = "2b2f59f7fccd2fcfbaf4306e33342e5d2be8f0ddd71af9eeca0c1f215e1e29aa" SRC_URI[md5sum] = "8a0585de48d8060a5394aae912342c95" sharedir = "${datadir}" FILES_${PN} = " \ ${bindir}/virt-clone \ ${bindir}/virt-image \ ${bindir}/virt-install \ ${bindir}/virt-convert \ ${bindir}/virt-xml \ ${sharedir}/virt-manager/virt-clone \ ${sharedir}/virt-manager/virt-image \ ${sharedir}/virt-manager/virt-install \ ${sharedir}/virt-manager/virt-convert \ ${sharedir}/virt-manager/virt-xml \ ${sharedir}/virt-manager/virtinst \ ${sharedir}/virt-manager/virtconv \ ${sharedir}/virt-manager/virtcli \ \ ${sharedir}/virt-manager/virt-manager \ ${sharedir}/virt-manager/virtManager \ ${sharedir}/virt-manager/ui \ ${sharedir}/virt-manager/icons \ ${sharedir}/icons \ ${sharedir}/appdata \ ${sharedir}/applications \ ${sharedir}/glib-2.0 \ ${@base_contains('DISTRO_FEATURES', 'x11', '${bindir}/virt-manager', '', d)} \ " DEPENDS = "nativesdk-perl" RDEPENDS_${PN} = " \ libvirt-python \ python-urlgrabber \ libxml2-python \ ${@base_contains('DISTRO_FEATURES', 'x11', 'python-pygtk', '', d)} \ " do_configure() { python setup.py configure } do_build() { python setup.py build --prefix=${prefix} } # virt-manager is the only command that requires graphical libraries. The # package does however not supply a --no-graphics argument or such to the # install program, which is understandable since distutils (which is # undocumented to a large degree) seems to be called with the complete file # list before the argument parsing is performed. To avoid that this command is # available when the package is built as part of a non-x11 distro, remove the # /usr/bin/virt-manager file. REMOVE_COMMAND = "${@base_contains('DISTRO_FEATURES', 'x11', '', 'rm ${D}${bindir}/virt-manager', d)}" do_install() { python setup.py install --prefix=${prefix} --root=${D} sh -c "${REMOVE_COMMAND}" }