File: 0001-vulkan-utils_gen-fix-for-python-3.14.patch

package info (click to toggle)
libplacebo 7.351.0-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 3,764 kB
  • sloc: ansic: 53,418; python: 578; cpp: 277; makefile: 7; sh: 3
file content (27 lines) | stat: -rw-r--r-- 910 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
From: Nicolas Chauvet <kwizart@gmail.com>
Date: Tue, 29 Jul 2025 11:42:35 +0200
Subject: vulkan/utils_gen: fix for python 3.14

Python 3.14+ has added more type checking. This patch fixes usage

Fixes: https://github.com/haasn/libplacebo/issues/335

Signed-off-by: Nicolas Chauvet <kwizart@gmail.com>
---
 src/vulkan/utils_gen.py | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/src/vulkan/utils_gen.py b/src/vulkan/utils_gen.py
index 9a97d35..9b803d8 100644
--- a/src/vulkan/utils_gen.py
+++ b/src/vulkan/utils_gen.py
@@ -202,7 +202,8 @@ if __name__ == '__main__':
     if not xmlfile or xmlfile == '':
         xmlfile = find_registry_xml(datadir)
 
-    registry = VkXML(ET.parse(xmlfile))
+    tree = ET.parse(xmlfile)
+    registry = VkXML(tree.getroot())
     with open(outfile, 'w') as f:
         f.write(TEMPLATE.render(
             vkresults = get_vkenum(registry, 'VkResult'),