swi-prolog: update to 9.2.9
[oi-userland.git] / components / desktop / libdbusmenu / patches / 02-fix-python.patch
blobeb8bec110896ab49b676dc819891be122a3f5cd1
1 --- libdbusmenu-16.04.0/tools/dbusmenu-bench.orig 2016-02-27 19:58:43.000000000 +0100
2 +++ libdbusmenu-16.04.0/tools/dbusmenu-bench 2023-11-23 20:17:44.777329961 +0100
3 @@ -61,7 +61,7 @@
5 def dump_properties(properties, prepend=""):
6 for key, value in properties.items():
7 - print "%s- %s: %s" % (prepend, key, value)
8 + print ("%s- %s: %s" % (prepend, key, value))
11 def run_test_sequence(menu, dump=False):
12 @@ -74,9 +74,9 @@
13 revision, layout = menu.GetLayout(dbus.Int32(0))
14 times["GetLayout"] = chrono.elapsed()
15 if dump:
16 - print "revision:", revision
17 - print "layout:"
18 - print layout
19 + print ("revision:", revision)
20 + print ("layout:")
21 + print (layout)
23 # Get ids
24 tree = ET.fromstring(layout)
25 @@ -89,17 +89,17 @@
26 children = menu.GetChildren(dbus.Int32(root_id), property_names)
27 times["GetChildren"] = chrono.elapsed()
28 if dump:
29 - print "children:"
30 + print ("children:")
31 for child in children:
32 id, properties = child
33 - print "- %d:" % id
34 + print ("- %d:" % id)
35 dump_properties(properties, prepend=" ")
37 chrono.restart()
38 properties = menu.GetProperties(dbus.Int32(child_id), property_names)
39 times["GetProperties"] = chrono.elapsed()
40 if dump:
41 - print "properties:"
42 + print ("properties:")
43 dump_properties(properties)
45 return times
46 @@ -109,7 +109,7 @@
48 def print_probe(prefix, name, value, timestamp):
49 value = int(value * 1000000)
50 - print "%(prefix)s.%(name)s:%(value)d@%(timestamp)d" % locals()
51 + print ("%(prefix)s.%(name)s:%(value)d@%(timestamp)d" % locals())
53 def main():
54 parser = OptionParser(usage = "%prog [options]")