diff mbox series

[v2,2/4] babeltrace2: Enable python plugins

Message ID 20250720090010.3122861-2-mingli.yu@eng.windriver.com
State New
Headers show
Series [v2,1/4] lttng-ust: Upgrade 2.13.9 -> 2.14.0 | expand

Commit Message

mingli.yu@eng.windriver.com July 20, 2025, 9 a.m. UTC
From: Mingli Yu <mingli.yu@windriver.com>

* The lttng-tools test fails as below as it needs bt2 module.
ERROR: ust/high-throughput/test_high_throughput_snapshot.py
===========================================================

Traceback (most recent call last):
  File "/usr/lib/lttng-tools/ptest/tests/regression/./ust/high-throughput/test_high_throughput_snapshot.py", line 26, in <module>
    import bt2
ModuleNotFoundError: No module named 'bt2'

Enable python plugins for babeltrace2 to provide the above support.

* Add swig-native to DEPENDS to fix the below configure error.
 | configure: error: SWIG 2.0.0 or newer is required to build the python bindings

Signed-off-by: Mingli Yu <mingli.yu@windriver.com>
---
 meta/recipes-kernel/lttng/babeltrace2_2.1.1.bb | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

Comments

Joao Marcos Costa July 21, 2025, 8:09 a.m. UTC | #1
Hello Mingli,

On 7/20/25 11:00, Yu, Mingli via lists.openembedded.org wrote:
> From: Mingli Yu <mingli.yu@windriver.com>
> 
> * The lttng-tools test fails as below as it needs bt2 module.
> ERROR: ust/high-throughput/test_high_throughput_snapshot.py
> ===========================================================
> 
> Traceback (most recent call last):
>    File "/usr/lib/lttng-tools/ptest/tests/regression/./ust/high-throughput/test_high_throughput_snapshot.py", line 26, in <module>
>      import bt2
> ModuleNotFoundError: No module named 'bt2'
> 
> Enable python plugins for babeltrace2 to provide the above support.
> 
> * Add swig-native to DEPENDS to fix the below configure error.
>   | configure: error: SWIG 2.0.0 or newer is required to build the python bindings
> 
> Signed-off-by: Mingli Yu <mingli.yu@windriver.com>
> ---
>   meta/recipes-kernel/lttng/babeltrace2_2.1.1.bb | 6 +++---
>   1 file changed, 3 insertions(+), 3 deletions(-)
> 
> diff --git a/meta/recipes-kernel/lttng/babeltrace2_2.1.1.bb b/meta/recipes-kernel/lttng/babeltrace2_2.1.1.bb
> index 8bab7f677a6..88f589eafbc 100644
> --- a/meta/recipes-kernel/lttng/babeltrace2_2.1.1.bb
> +++ b/meta/recipes-kernel/lttng/babeltrace2_2.1.1.bb
> @@ -5,7 +5,7 @@ BUGTRACKER = "https://bugs.lttng.org/projects/babeltrace"
>   LICENSE = "MIT & GPL-2.0-only & LGPL-2.1-only & BSD-2-Clause & BSD-4-Clause & GPL-3.0-or-later & CC-BY-SA-4.0 & PSF-2.0"
>   LIC_FILES_CHKSUM = "file://LICENSE;md5=f6b015e4f388d6e78adb1b1f9a887d06"
>   
> -DEPENDS = "glib-2.0 util-linux popt bison-native flex-native virtual/libiconv"
> +DEPENDS = "glib-2.0 util-linux popt bison-native flex-native virtual/libiconv swig-native"
>   
>   SRC_URI = "git://git.efficios.com/babeltrace.git;branch=stable-2.1;protocol=https;tag=v${PV} \
>              file://run-ptest \
> @@ -19,13 +19,13 @@ UPSTREAM_CHECK_GITTAGREGEX = "v(?P<pver>2(\.\d+)+)$"
>   
>   inherit autotools pkgconfig ptest python3targetconfig
>   
> -EXTRA_OECONF = "--disable-debug-info --disable-Werror"
> +EXTRA_OECONF = "--disable-debug-info --disable-Werror --enable-python-plugins --enable-python-bindings"
>   
>   PACKAGECONFIG ??= "manpages"
>   PACKAGECONFIG[manpages] = ", --disable-man-pages, asciidoc-native xmlto-native"
>   
>   FILES:${PN}-staticdev += "${libdir}/babeltrace2/plugins/*.a"
> -FILES:${PN} += "${libdir}/babeltrace2/plugins/*.so"
> +FILES:${PN} += "${libdir}/babeltrace2/plugins/*.so ${PYTHON_SITEPACKAGES_DIR}/*"
>   
>   ASNEEDED = ""
>   LDFLAGS += "${@bb.utils.contains('DISTRO_FEATURES', 'ld-is-lld ptest', '-fuse-ld=bfd ', '', d)}"
> 
> 
> 
> -=-=-=-=-=-=-=-=-=-=-=-
> Links: You receive all messages sent to this group.
> View/Reply Online (#220615): https://lists.openembedded.org/g/openembedded-core/message/220615
> Mute This Topic: https://lists.openembedded.org/mt/114249009/8026893
> Group Owner: openembedded-core+owner@lists.openembedded.org
> Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [joaomarcos.costa@bootlin.com]
> -=-=-=-=-=-=-=-=-=-=-=-
> 

There are some ptest errors in the autobuilder:
- 
https://autobuilder.yoctoproject.org/valkyrie/?#/builders/61/builds/1923/steps/12/logs/stdio
- 
https://autobuilder.yoctoproject.org/valkyrie/?#/builders/73/builds/1931/steps/12/logs/stdio

Could you please take a look?

Thanks!
Yu, Mingli July 23, 2025, 2:10 a.m. UTC | #2
On 7/21/25 16:09, Joao Marcos Costa wrote:
> CAUTION: This email comes from a non Wind River email account!
> Do not click links or open attachments unless you recognize the sender 
> and know the content is safe.
> 
> Hello Mingli,
> 
> On 7/20/25 11:00, Yu, Mingli via lists.openembedded.org wrote:
>> From: Mingli Yu <mingli.yu@windriver.com>
>>
>> * The lttng-tools test fails as below as it needs bt2 module.
>> ERROR: ust/high-throughput/test_high_throughput_snapshot.py
>> ===========================================================
>>
>> Traceback (most recent call last):
>>    File 
>> "/usr/lib/lttng-tools/ptest/tests/regression/./ust/high-throughput/test_high_throughput_snapshot.py", line 26, in <module>
>>      import bt2
>> ModuleNotFoundError: No module named 'bt2'
>>
>> Enable python plugins for babeltrace2 to provide the above support.
>>
>> * Add swig-native to DEPENDS to fix the below configure error.
>>   | configure: error: SWIG 2.0.0 or newer is required to build the 
>> python bindings
>>
>> Signed-off-by: Mingli Yu <mingli.yu@windriver.com>
>> ---
>>   meta/recipes-kernel/lttng/babeltrace2_2.1.1.bb | 6 +++---
>>   1 file changed, 3 insertions(+), 3 deletions(-)
>>
>> diff --git a/meta/recipes-kernel/lttng/babeltrace2_2.1.1.bb 
>> b/meta/recipes-kernel/lttng/babeltrace2_2.1.1.bb
>> index 8bab7f677a6..88f589eafbc 100644
>> --- a/meta/recipes-kernel/lttng/babeltrace2_2.1.1.bb
>> +++ b/meta/recipes-kernel/lttng/babeltrace2_2.1.1.bb
>> @@ -5,7 +5,7 @@ BUGTRACKER = "https://bugs.lttng.org/projects/babeltrace"
>>   LICENSE = "MIT & GPL-2.0-only & LGPL-2.1-only & BSD-2-Clause & 
>> BSD-4-Clause & GPL-3.0-or-later & CC-BY-SA-4.0 & PSF-2.0"
>>   LIC_FILES_CHKSUM = 
>> "file://LICENSE;md5=f6b015e4f388d6e78adb1b1f9a887d06"
>>
>> -DEPENDS = "glib-2.0 util-linux popt bison-native flex-native 
>> virtual/libiconv"
>> +DEPENDS = "glib-2.0 util-linux popt bison-native flex-native 
>> virtual/libiconv swig-native"
>>
>>   SRC_URI = 
>> "git://git.efficios.com/babeltrace.git;branch=stable-2.1;protocol=https;tag=v${PV} \
>>              file://run-ptest \
>> @@ -19,13 +19,13 @@ UPSTREAM_CHECK_GITTAGREGEX = "v(?P<pver>2(\.\d+)+)$"
>>
>>   inherit autotools pkgconfig ptest python3targetconfig
>>
>> -EXTRA_OECONF = "--disable-debug-info --disable-Werror"
>> +EXTRA_OECONF = "--disable-debug-info --disable-Werror 
>> --enable-python-plugins --enable-python-bindings"
>>
>>   PACKAGECONFIG ??= "manpages"
>>   PACKAGECONFIG[manpages] = ", --disable-man-pages, asciidoc-native 
>> xmlto-native"
>>
>>   FILES:${PN}-staticdev += "${libdir}/babeltrace2/plugins/*.a"
>> -FILES:${PN} += "${libdir}/babeltrace2/plugins/*.so"
>> +FILES:${PN} += "${libdir}/babeltrace2/plugins/*.so 
>> ${PYTHON_SITEPACKAGES_DIR}/*"
>>
>>   ASNEEDED = ""
>>   LDFLAGS += "${@bb.utils.contains('DISTRO_FEATURES', 'ld-is-lld 
>> ptest', '-fuse-ld=bfd ', '', d)}"
>>
>>
>>
>> -=-=-=-=-=-=-=-=-=-=-=-
>> Links: You receive all messages sent to this group.
>> View/Reply Online (#220615): 
>> https://lists.openembedded.org/g/openembedded-core/message/220615
>> Mute This Topic: https://lists.openembedded.org/mt/114249009/8026893
>> Group Owner: openembedded-core+owner@lists.openembedded.org
>> Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
>> [joaomarcos.costa@bootlin.com]
>> -=-=-=-=-=-=-=-=-=-=-=-
>>
> 
> There are some ptest errors in the autobuilder:
> -
> https://autobuilder.yoctoproject.org/valkyrie/?#/builders/61/builds/1923/steps/12/logs/stdio
> -
> https://autobuilder.yoctoproject.org/valkyrie/?#/builders/73/builds/1931/steps/12/logs/stdio
> 
> Could you please take a look?

I will look into this.

Could I access the ptest-runner.log such as 
tmp/work/qemux86_64-poky-linux/core-image-ptest-babeltrace2/1.0/testimage/ptest_log.20250710153833/ptest-runner.log 
corresponding to 
https://autobuilder.yoctoproject.org/valkyrie/?#/builders/61/builds/1923/steps/12/logs/stdio?

Thanks,
Mingli

> 
> Thanks!
> 
> -- 
> Best regards,
> João Marcos Costa
Mathieu Dubois-Briand July 23, 2025, 5:51 a.m. UTC | #3
>> There are some ptest errors in the autobuilder:
>> -
>> https://autobuilder.yoctoproject.org/valkyrie/?#/builders/61/builds/1923/steps/12/logs/stdio
>> -
>> https://autobuilder.yoctoproject.org/valkyrie/?#/builders/73/builds/1931/steps/12/logs/stdio
>> 
>> Could you please take a look?
>
> I will look into this.
>
> Could I access the ptest-runner.log such as 
> tmp/work/qemux86_64-poky-linux/core-image-ptest-babeltrace2/1.0/testimage/ptest_log.20250710153833/ptest-runner.log 
> corresponding to 
> https://autobuilder.yoctoproject.org/valkyrie/?#/builders/61/builds/1923/steps/12/logs/stdio?

Hi Mingli,

Ptest logs can be found here:

https://valkyrie.yocto.io/pub/non-release/20250720-85/testresults/qemuarm64-ptest/core-image-ptest-lttng-tools/
https://valkyrie.yocto.io/pub/non-release/20250720-85/testresults/qemux86-64-ptest/core-image-ptest-lttng-tools/

>
> Thanks,
> Mingli
>
>> 
>> Thanks!
>> 
>> -- 
>> Best regards,
>> João Marcos Costa
Yu, Mingli July 24, 2025, 5:58 a.m. UTC | #4
On 7/23/25 13:51, Mathieu Dubois-Briand wrote:
> CAUTION: This email comes from a non Wind River email account!
> Do not click links or open attachments unless you recognize the sender and know the content is safe.
> 
>>> There are some ptest errors in the autobuilder:
>>> -
>>> https://autobuilder.yoctoproject.org/valkyrie/?#/builders/61/builds/1923/steps/12/logs/stdio
>>> -
>>> https://autobuilder.yoctoproject.org/valkyrie/?#/builders/73/builds/1931/steps/12/logs/stdio
>>>
>>> Could you please take a look?
>>
>> I will look into this.
>>
>> Could I access the ptest-runner.log such as
>> tmp/work/qemux86_64-poky-linux/core-image-ptest-babeltrace2/1.0/testimage/ptest_log.20250710153833/ptest-runner.log
>> corresponding to
>> https://autobuilder.yoctoproject.org/valkyrie/?#/builders/61/builds/1923/steps/12/logs/stdio?
> 
> Hi Mingli,
> 
> Ptest logs can be found here:
> 
> https://valkyrie.yocto.io/pub/non-release/20250720-85/testresults/qemuarm64-ptest/core-image-ptest-lttng-tools/
> https://valkyrie.yocto.io/pub/non-release/20250720-85/testresults/qemux86-64-ptest/core-image-ptest-lttng-tools/

I didn't find ptest-runner.log under the location you pointed.
The ptest-runner.log such as 
tmp/work/qemux86_64-poky-linux/core-image-ptest-babeltrace2/1.0/testimage/ptest_log.20250710153833/ptest-runner.log.

Thanks,
Mingli

> 
>>
>> Thanks,
>> Mingli
>>
>>>
>>> Thanks!
>>>
>>> --
>>> Best regards,
>>> João Marcos Costa
> 
> --
> Mathieu Dubois-Briand, Bootlin
> Embedded Linux and Kernel engineering
> https://bootlin.com
>
Mathieu Dubois-Briand July 24, 2025, 9:53 a.m. UTC | #5
On Thu Jul 24, 2025 at 7:58 AM CEST, Mingli Yu wrote:
>
>
> On 7/23/25 13:51, Mathieu Dubois-Briand wrote:
>> CAUTION: This email comes from a non Wind River email account!
>> Do not click links or open attachments unless you recognize the sender and know the content is safe.
>> 
>>>> There are some ptest errors in the autobuilder:
>>>> -
>>>> https://autobuilder.yoctoproject.org/valkyrie/?#/builders/61/builds/1923/steps/12/logs/stdio
>>>> -
>>>> https://autobuilder.yoctoproject.org/valkyrie/?#/builders/73/builds/1931/steps/12/logs/stdio
>>>>
>>>> Could you please take a look?
>>>
>>> I will look into this.
>>>
>>> Could I access the ptest-runner.log such as
>>> tmp/work/qemux86_64-poky-linux/core-image-ptest-babeltrace2/1.0/testimage/ptest_log.20250710153833/ptest-runner.log
>>> corresponding to
>>> https://autobuilder.yoctoproject.org/valkyrie/?#/builders/61/builds/1923/steps/12/logs/stdio?
>> 
>> Hi Mingli,
>> 
>> Ptest logs can be found here:
>> 
>> https://valkyrie.yocto.io/pub/non-release/20250720-85/testresults/qemuarm64-ptest/core-image-ptest-lttng-tools/
>> https://valkyrie.yocto.io/pub/non-release/20250720-85/testresults/qemux86-64-ptest/core-image-ptest-lttng-tools/
>
> I didn't find ptest-runner.log under the location you pointed.
> The ptest-runner.log such as 
> tmp/work/qemux86_64-poky-linux/core-image-ptest-babeltrace2/1.0/testimage/ptest_log.20250710153833/ptest-runner.log.
>
> Thanks,
> Mingli
>
>> 
>>>
>>> Thanks,
>>> Mingli
>>>
>>>>
>>>> Thanks!
>>>>
>>>> --
>>>> Best regards,
>>>> João Marcos Costa
>> 
>> --
>> Mathieu Dubois-Briand, Bootlin
>> Embedded Linux and Kernel engineering
>> https://bootlin.com
>> 

Ok, I relaunched a build, to be able to capture this file. I've attached
tmp/work/qemuarm64-poky-linux/core-image-ptest-babeltrace2/1.0/testimage/ptest_log.20250724082617/ptest-runner.log
to this mail.

https://autobuilder.yoctoproject.org/valkyrie/?#/builders/61/builds/1951
https://valkyrie.yocto.io/pub/non-release/20250720-85/testresults/qemux86-64-ptest/core-image-ptest-babeltrace2/

Best regards,
Mathieu
diff mbox series

Patch

diff --git a/meta/recipes-kernel/lttng/babeltrace2_2.1.1.bb b/meta/recipes-kernel/lttng/babeltrace2_2.1.1.bb
index 8bab7f677a6..88f589eafbc 100644
--- a/meta/recipes-kernel/lttng/babeltrace2_2.1.1.bb
+++ b/meta/recipes-kernel/lttng/babeltrace2_2.1.1.bb
@@ -5,7 +5,7 @@  BUGTRACKER = "https://bugs.lttng.org/projects/babeltrace"
 LICENSE = "MIT & GPL-2.0-only & LGPL-2.1-only & BSD-2-Clause & BSD-4-Clause & GPL-3.0-or-later & CC-BY-SA-4.0 & PSF-2.0"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=f6b015e4f388d6e78adb1b1f9a887d06"
 
-DEPENDS = "glib-2.0 util-linux popt bison-native flex-native virtual/libiconv"
+DEPENDS = "glib-2.0 util-linux popt bison-native flex-native virtual/libiconv swig-native"
 
 SRC_URI = "git://git.efficios.com/babeltrace.git;branch=stable-2.1;protocol=https;tag=v${PV} \
            file://run-ptest \
@@ -19,13 +19,13 @@  UPSTREAM_CHECK_GITTAGREGEX = "v(?P<pver>2(\.\d+)+)$"
 
 inherit autotools pkgconfig ptest python3targetconfig
 
-EXTRA_OECONF = "--disable-debug-info --disable-Werror"
+EXTRA_OECONF = "--disable-debug-info --disable-Werror --enable-python-plugins --enable-python-bindings"
 
 PACKAGECONFIG ??= "manpages"
 PACKAGECONFIG[manpages] = ", --disable-man-pages, asciidoc-native xmlto-native"
 
 FILES:${PN}-staticdev += "${libdir}/babeltrace2/plugins/*.a"
-FILES:${PN} += "${libdir}/babeltrace2/plugins/*.so"
+FILES:${PN} += "${libdir}/babeltrace2/plugins/*.so ${PYTHON_SITEPACKAGES_DIR}/*"
 
 ASNEEDED = ""
 LDFLAGS += "${@bb.utils.contains('DISTRO_FEATURES', 'ld-is-lld ptest', '-fuse-ld=bfd ', '', d)}"