On Tue, Jul 14, 2009 at 9:58 AM, Andrea Grandi<[email protected]> wrote:
> Hi all,
>
> I'm writing a Python binding for a C library that runs on Maemo and,
> since it's the first binding I write, I've some questions.

I hope that it is not one of the official Maemo C libraries, because
in that case you might want to coordinate with the PyMaemo team
(specially create a bug entry for it).

Right now we are working on hildon-notify and MAFW bindings.

> I've read the chapter "Extending Python with C" in a couple of manuals
> and I've read the online documentation too, but some parts are no
> covered yet.

For sure, the GObject machinery has its own way to interface with
Python, through the pygobject tools.

There is a (mostly undocumented, AFAIK) tool from PyGtk called
"codegen", that can be used to automate most of the work of generating
bindings for GObject based libraries. python-hildon uses this tool to
automate most of the binding.

My suggestion is to look at some existing (simple) binding and do your
work based on it. I would suggest taking a look at python-hildon, and
in a script called "hildon_gen_defs.sh" there where we automate most
of the process:

https://garage.maemo.org/svn/pymaemo/packages/python-hildon/trunk/

Hope that helps,
-- 
Anderson Lizardo
OpenBossa Labs - INdT
Manaus - Brazil
_______________________________________________
maemo-developers mailing list
[email protected]
https://lists.maemo.org/mailman/listinfo/maemo-developers

Reply via email to