diff options
| author | Bruce Ashfield <bruce.ashfield@windriver.com> | 2014-02-05 16:41:55 -0500 |
|---|---|---|
| committer | Bruce Ashfield <bruce.ashfield@windriver.com> | 2014-02-05 16:41:55 -0500 |
| commit | 41101a7a51fd2a98fda57ff2493e25f96748359d (patch) | |
| tree | 33a9f5c0a77baa8c633677562f13627d6f423f11 | |
| parent | 142477933dae9b4561ed3f28753d26ab4f150c2e (diff) | |
| download | meta-virtualization-41101a7a51fd2a98fda57ff2493e25f96748359d.tar.gz | |
libvirt: fix python packaging race
The tasks responsible for compiling and installing the python support
were racing against packaging. As a result, a clean build would not
have anything in libvirt-python, but subsequent builds would.
By moving to _appends, we control the order and always get properly
packaged.
Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
| -rw-r--r-- | recipes-extended/libvirt/libvirt-python.inc | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/recipes-extended/libvirt/libvirt-python.inc b/recipes-extended/libvirt/libvirt-python.inc index c630bbba..2144a562 100644 --- a/recipes-extended/libvirt/libvirt-python.inc +++ b/recipes-extended/libvirt/libvirt-python.inc | |||
| @@ -13,7 +13,7 @@ PACKAGES += "${PN}-python-staticdev ${PN}-python-dev ${PN}-python-dbg ${PN}-pyth | |||
| 13 | FILES_${PN}-python-staticdev += "${PYTHON_SITEPACKAGES_DIR}/*.a" | 13 | FILES_${PN}-python-staticdev += "${PYTHON_SITEPACKAGES_DIR}/*.a" |
| 14 | FILES_${PN}-python-dev += "${PYTHON_SITEPACKAGES_DIR}/*.la" | 14 | FILES_${PN}-python-dev += "${PYTHON_SITEPACKAGES_DIR}/*.la" |
| 15 | FILES_${PN}-python-dbg += "${PYTHON_SITEPACKAGES_DIR}/.debug/" | 15 | FILES_${PN}-python-dbg += "${PYTHON_SITEPACKAGES_DIR}/.debug/" |
| 16 | FILES_${PN}-python += "${bindir}/* ${libdir}/* ${libdir}/${PYTHON_DIR}/*" | 16 | FILES_${PN}-python = "${bindir}/* ${libdir}/* ${libdir}/${PYTHON_DIR}/*" |
| 17 | 17 | ||
| 18 | SRC_URI += "http://libvirt.org/sources/python/libvirt-python-${PV}.tar.gz;name=libvirt_python" | 18 | SRC_URI += "http://libvirt.org/sources/python/libvirt-python-${PV}.tar.gz;name=libvirt_python" |
| 19 | SRC_URI += "file://libvirt_api_xml_path.patch;patchdir=../libvirt-python-${PV}" | 19 | SRC_URI += "file://libvirt_api_xml_path.patch;patchdir=../libvirt-python-${PV}" |
| @@ -39,19 +39,17 @@ python __anonymous () { | |||
| 39 | d.setVar('LIBVIRT_PYTHON_ENABLE', '0') | 39 | d.setVar('LIBVIRT_PYTHON_ENABLE', '0') |
| 40 | } | 40 | } |
| 41 | 41 | ||
| 42 | do_compile_python() { | 42 | do_compile_append() { |
| 43 | if [ "${LIBVIRT_PYTHON_ENABLE}" = "1" ]; then | 43 | if [ "${LIBVIRT_PYTHON_ENABLE}" = "1" ]; then |
| 44 | cd ${WORKDIR}/libvirt-python-${PV} && \ | 44 | cd ${WORKDIR}/libvirt-python-${PV} && \ |
| 45 | ${STAGING_BINDIR_NATIVE}/python-native/python setup.py build | 45 | ${STAGING_BINDIR_NATIVE}/python-native/python setup.py build |
| 46 | fi | 46 | fi |
| 47 | } | 47 | } |
| 48 | addtask do_compile_python before do_install after do_compile | 48 | |
| 49 | 49 | do_install_append() { | |
| 50 | do_install_python() { | ||
| 51 | if [ "${LIBVIRT_PYTHON_ENABLE}" = "1" ]; then | 50 | if [ "${LIBVIRT_PYTHON_ENABLE}" = "1" ]; then |
| 52 | cd ${WORKDIR}/${PN}-python-${PV} && \ | 51 | cd ${WORKDIR}/${PN}-python-${PV} && \ |
| 53 | ${STAGING_BINDIR_NATIVE}/python-native/python setup.py install \ | 52 | ${STAGING_BINDIR_NATIVE}/python-native/python setup.py install \ |
| 54 | --install-lib=${D}/${PYTHON_SITEPACKAGES_DIR} ${LIBVIRT_INSTALL_ARGS} | 53 | --install-lib=${D}/${PYTHON_SITEPACKAGES_DIR} ${LIBVIRT_INSTALL_ARGS} |
| 55 | fi | 54 | fi |
| 56 | } | 55 | } |
| 57 | addtask do_install_python before do_populate_sysroot after do_install | ||
