[yocto,meta-openembedded,master,warrior,1/2] python-pywbem: solved the conflict with python3-pywbem

Submitted by Zang Ruochen on June 13, 2019, 3:25 a.m. | Patch ID: 162167

Details

Message ID 20190613032534.9975-2-zangrc.fnst@cn.fujitsu.com
State Accepted
Commit cdc746763189818b16c6eec35375a162359d4d27
Headers show

Commit Message

Zang Ruochen June 13, 2019, 3:25 a.m.
-Use update-alternatives class to resolve conflicts with python3-pywbem.

Signed-off-by: Zang Ruochen <zangrc.fnst@cn.fujitsu.com>
---
 .../recipes-extended/pywbem/python-pywbem_0.11.0.bb      | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

Patch hide | download patch | download mbox

diff --git a/meta-python/recipes-extended/pywbem/python-pywbem_0.11.0.bb b/meta-python/recipes-extended/pywbem/python-pywbem_0.11.0.bb
index 741074907..a699f1c7e 100644
--- a/meta-python/recipes-extended/pywbem/python-pywbem_0.11.0.bb
+++ b/meta-python/recipes-extended/pywbem/python-pywbem_0.11.0.bb
@@ -1,5 +1,5 @@ 
 require python-pywbem.inc
-inherit setuptools
+inherit setuptools update-alternatives
 
 DEPENDS += " \
     ${PYTHON_PN}-m2crypto-native \
@@ -11,3 +11,10 @@  RDEPENDS_${PN}_class-target += "\
     ${PYTHON_PN}-m2crypto \
     ${PYTHON_PN}-subprocess \
 "
+
+ALTERNATIVE_${PN} = "mof_compiler pywbemcli wbemcli"
+ALTERNATIVE_TARGET[mof_compiler] = "${bindir}/mof_compiler"
+ALTERNATIVE_TARGET[pywbemcli] = "${bindir}/pywbemcli"
+ALTERNATIVE_TARGET[wbemcli] = "${bindir}/wbemcli"
+
+ALTERNATIVE_PRIORITY = "30"