diff options
author | Khem Raj <raj.khem@gmail.com> | 2025-08-11 22:00:03 -0700 |
---|---|---|
committer | Khem Raj <raj.khem@gmail.com> | 2025-08-13 10:09:25 -0700 |
commit | 32f2857c6781f0b93c8b5527413c482eee6dc5f1 (patch) | |
tree | 956aa3ce6da85d6b82d299304a7ebc59906dd4d1 | |
parent | 618b14ef14966c4fc26cf913edcbdd7789709bba (diff) | |
download | meta-openembedded-32f2857c6781f0b93c8b5527413c482eee6dc5f1.tar.gz |
libplacebo: Fix build with latest python 3.14
Fixes
FAILED: [code=1] src/vulkan/utils_gen.c
/home/kraj200/yoe/build/tmp/work/riscv64imafdc-yoe-linux/libplacebo/7.351.0/recipe-sysroot-native/usr/bin/meson.real --
↪ internal exe --unpickle /home/kraj200/yoe/build/tmp/work/riscv64imafdc-yoe-linux/libplacebo/7.351.0/build/meson-private/
↪ meson_exe_nativepython3_7e48a7413404982655e79073cf3065c6194271bf.dat
while executing ['/home/kraj200/yoe/build/tmp/work/riscv64imafdc-yoe-linux/libplacebo/7.351.0/recipe-sysroot-native/usr/bin/
↪ nativepython3', '../sources/libplacebo-7.351.0/src/vulkan/utils_gen.py', '/usr/share', '/home/kraj200/yoe/build/tmp/work/
↪ riscv64imafdc-yoe-linux/libplacebo/7.351.0/recipe-sysroot/usr/share/vulkan/registry/vk.xml', 'src/vulkan/utils_gen.c']
--- stdout ---
--- stderr ---
Traceback (most recent call last):
File "/home/kraj200/yoe/build/tmp/work/riscv64imafdc-yoe-linux/libplacebo/7.351.0/build/../sources/libplacebo-7.351.0/src/
↪ vulkan/utils_gen.py", line 205, in <module>
registry = VkXML(ET.parse(xmlfile))
File "/home/kraj200/yoe/build/tmp/work/riscv64imafdc-yoe-linux/libplacebo/7.351.0/build/../sources/libplacebo-7.351.0/src/
↪ vulkan/utils_gen.py", line 50, in __init__
super().__init__(*args, **kwargs)
~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^
File "/home/kraj200/yoe/build/tmp/work/riscv64imafdc-yoe-linux/libplacebo/7.351.0/recipe-sysroot-native/usr/lib/python3.13/
↪ xml/etree/ElementTree.py", line 527, in __init__
raise TypeError('expected an Element, not %s' %
type(element).__name__)
TypeError: expected an Element, not ElementTree
Signed-off-by: Khem Raj <raj.khem@gmail.com>
-rw-r--r-- | meta-oe/recipes-multimedia/mplayer/libplacebo/0001-vulkan-utils_gen-fix-for-python-3.14.patch | 30 | ||||
-rw-r--r-- | meta-oe/recipes-multimedia/mplayer/libplacebo_7.351.0.bb | 4 |
2 files changed, 33 insertions, 1 deletions
diff --git a/meta-oe/recipes-multimedia/mplayer/libplacebo/0001-vulkan-utils_gen-fix-for-python-3.14.patch b/meta-oe/recipes-multimedia/mplayer/libplacebo/0001-vulkan-utils_gen-fix-for-python-3.14.patch new file mode 100644 index 0000000000..4e381af340 --- /dev/null +++ b/meta-oe/recipes-multimedia/mplayer/libplacebo/0001-vulkan-utils_gen-fix-for-python-3.14.patch | |||
@@ -0,0 +1,30 @@ | |||
1 | From ae40237869ae1db4de7f6d86865bc99820852495 Mon Sep 17 00:00:00 2001 | ||
2 | From: Nicolas Chauvet <kwizart@gmail.com> | ||
3 | Date: Tue, 29 Jul 2025 11:42:35 +0200 | ||
4 | Subject: [PATCH] vulkan/utils_gen: fix for python 3.14 | ||
5 | |||
6 | Python 3.14+ has added more type checking. This patch fixes usage | ||
7 | |||
8 | Fixes: https://github.com/haasn/libplacebo/issues/335 | ||
9 | |||
10 | Upstream-Status: Backport [https://code.videolan.org/videolan/libplacebo/-/commit/12509c0f1ee8c22ae163017f0a5e7b8a9d983a17] | ||
11 | Signed-off-by: Nicolas Chauvet <kwizart@gmail.com> | ||
12 | Signed-off-by: Khem Raj <raj.khem@gmail.com> | ||
13 | --- | ||
14 | src/vulkan/utils_gen.py | 3 ++- | ||
15 | 1 file changed, 2 insertions(+), 1 deletion(-) | ||
16 | |||
17 | diff --git a/src/vulkan/utils_gen.py b/src/vulkan/utils_gen.py | ||
18 | index 9a97d35f..9b803d82 100644 | ||
19 | --- a/src/vulkan/utils_gen.py | ||
20 | +++ b/src/vulkan/utils_gen.py | ||
21 | @@ -202,7 +202,8 @@ if __name__ == '__main__': | ||
22 | if not xmlfile or xmlfile == '': | ||
23 | xmlfile = find_registry_xml(datadir) | ||
24 | |||
25 | - registry = VkXML(ET.parse(xmlfile)) | ||
26 | + tree = ET.parse(xmlfile) | ||
27 | + registry = VkXML(tree.getroot()) | ||
28 | with open(outfile, 'w') as f: | ||
29 | f.write(TEMPLATE.render( | ||
30 | vkresults = get_vkenum(registry, 'VkResult'), | ||
diff --git a/meta-oe/recipes-multimedia/mplayer/libplacebo_7.351.0.bb b/meta-oe/recipes-multimedia/mplayer/libplacebo_7.351.0.bb index 68a29dde91..3a1096bb57 100644 --- a/meta-oe/recipes-multimedia/mplayer/libplacebo_7.351.0.bb +++ b/meta-oe/recipes-multimedia/mplayer/libplacebo_7.351.0.bb | |||
@@ -4,7 +4,9 @@ LIC_FILES_CHKSUM = "file://LICENSE;md5=435ed639f84d4585d93824e7da3d85da" | |||
4 | 4 | ||
5 | DEPENDS += "fastfloat glad-native python3-mako-native python3-jinja2-native vulkan-headers" | 5 | DEPENDS += "fastfloat glad-native python3-mako-native python3-jinja2-native vulkan-headers" |
6 | 6 | ||
7 | SRC_URI = "git://code.videolan.org/videolan/libplacebo.git;protocol=https;branch=v7.351" | 7 | SRC_URI = "git://code.videolan.org/videolan/libplacebo.git;protocol=https;branch=v7.351 \ |
8 | file://0001-vulkan-utils_gen-fix-for-python-3.14.patch \ | ||
9 | " | ||
8 | SRCREV = "3188549fba13bbdf3a5a98de2a38c2e71f04e21e" | 10 | SRCREV = "3188549fba13bbdf3a5a98de2a38c2e71f04e21e" |
9 | 11 | ||
10 | inherit meson pkgconfig | 12 | inherit meson pkgconfig |