GNOME Bugzilla – Bug 350153
h2def.py doesn't handle interfaces correctly
Last modified: 2012-02-10 08:19:01 UTC
h2def.py currently doesn't handle interfaces correctly, and generates define-object sections for them. It should instead generate define-interface sections.
Created attachment 70308 [details] [review] patch This patch is a fairly trivial change, and makes it emit define-interface sections for any type whose parent is GTypeInterface. It doesn't work for types derived from other interfaces, but it shouldn't be any worse than the existing behaviour. I haven't done extensive testing, but it seems to work for Rhythmbox and Tinymail.
You could also try defsgen.py which uses the ctypes module to extract type info from the installed library. It correctly identifies interfaces and boxed types as well as object types, enums and flags.
codegen and the static bindings are obsolete since pygobject 3.0, which is GI only. Thanks!