Skip to contentSkip to conversation

lttng-tools: add PACKAGECONFIG to support --enable-python-bindings and lttng-ust

PATCH New Hongxu Jia 1 participant 2 messages Sep 4, 2014

lore
Share & tools
lore

Hongxu Jia

author
#0 lore raw

v2 cover lttng-tools: add PACKAGECONFIG to support --enable-python-bindings and lttng-ust

Changed in V2:
The python-bindings requires swig-native as DEPENDS, and swig-native is not in oe-core, so disable python-bindings by default

//Hongxu

The following changes since commit a44006262cf3b810ec78b4cccd8076102a7a0f3e:

distro/poky: Add Debian 7.5 and 7.6 version as validated (2014-09-03 16:00:29 +0100)

are available in the git repository at:

git://git.pokylinux.org/poky-contrib hongxu/fix-lttng-tools
http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=hongxu/fix-lttng-tools

Hongxu Jia (1):
lttng-tools: add PACKAGECONFIG to support --enable-python-bindings and
lttng-ust

 meta/recipes-kernel/lttng/lttng-tools_2.5.0.bb | 19 ++++++++++++++++---
 1 file changed, 16 insertions(+), 3 deletions(-)
Signature · 1 line
1.9.1
author
#1 lore raw

PATCH v2 1/1 lttng-tools: add PACKAGECONFIG to support --enable-python-bindings and lttng-ust

Add PACKAGECONFIG to support --enable-python-bindings Add PACKAGECONFIG to support lttng-ust

And python-bindings requires swig-native as DEPENDS, and swig-native is not in oe-core, so disable python-bindings by default

---
 meta/recipes-kernel/lttng/lttng-tools_2.5.0.bb | 19 ++++++++++++++++---
 1 file changed, 16 insertions(+), 3 deletions(-)
meta/recipes-kernel/lttng/lttng-tools_2.5.0.bb +16 -3
index 1ec0f4a..fd44aa5 100644
@@ -15,6 +15,14 @@ RDEPENDS_${PN}-ptest += "make perl bash"
 SRCREV = "8b27cacb277c2cdab791139b08da8eb87ab14a88"
 PV = "v2.5.0"
 
+PYTHON_OPTION = "am_cv_python_pyexecdir='${libdir}/python${PYTHON_BASEVERSION}/site-packages' \
+                 am_cv_python_pythondir='${libdir}/python${PYTHON_BASEVERSION}/site-packages' \
+                 PYTHON_INCLUDE='-I${STAGING_INCDIR}/python${PYTHON_BASEVERSION}' \
+"
+PACKAGECONFIG ??= "lttng-ust"
+PACKAGECONFIG[python] = "--enable-python-bindings ${PYTHON_OPTION},,python swig-native"
+PACKAGECONFIG[lttng-ust] = ", --disable-lttng-ust, lttng-ust"
+
 SRC_URI = "git://git.lttng.org/lttng-tools.git;branch=stable-2.5 \
            file://runtest-2.4.0.patch \
            file://run-ptest \
@@ -26,12 +34,17 @@ inherit autotools-brokensep ptest pkgconfig
 
 export KERNELDIR="${STAGING_KERNEL_DIR}"
 
-FILES_${PN} += "${libdir}/lttng/libexec/* ${datadir}/xml/lttng"
-FILES_${PN}-dbg += "${libdir}/lttng/libexec/.debug"
+FILES_${PN} += "${libdir}/lttng/libexec/* ${datadir}/xml/lttng \
+                ${libdir}/python${PYTHON_BASEVERSION}/site-packages/*"
+FILES_${PN}-dbg += "${libdir}/lttng/libexec/.debug \
+                    ${libdir}/python2.7/site-packages/.debug"
+FILES_${PN}-staticdev += "${libdir}/python${PYTHON_BASEVERSION}/site-packages/*.a"
+FILES_${PN}-dev += "${libdir}/python${PYTHON_BASEVERSION}/site-packages/*.la"
 
 # Since files are installed into ${libdir}/lttng/libexec we match 
 # the libexec insane test so skip it.
-INSANE_SKIP_${PN} = "libexec"
+# Python module needs to keep _lttng.so
+INSANE_SKIP_${PN} = "libexec dev-so"
 INSANE_SKIP_${PN}-dbg = "libexec"
 
 do_configure_prepend () {
Signature · 1 line
1.9.1