D-BUS PHP Bindings

One of the project I am working on right now involves the GNOME based architecture, including lots of usage of scratchbox Aphophis R4, having GTK+ running under kdrive and D-BUS as unified IPC mechanism. As this project also involves the web-interface I had decided to go for lighttpd based web-server backed with PHP as server side scripting language. So, now what is the problem?

As for GTK+, it internally uses Glib + GObject combination so it is not tough to decide to go for dbus-glib bindings for writing dbus services. So, far so good, but for clients which doesn’t having native language dbus bindings? Yes, we wanted to call one of this dbus-glib written service using PHP, and as of now there is no stable d-bus PHP binding available, so we can’t write d-bus based client directly into the PHP, until we use “exec” and call C binary which internally uses the dbus-glib. But this is not scalable solution, as I wanted to write signals based mechanism with PHP, and we might end up writing the so many small applications, which duplicates the lots of work, as these functionalities also need to be shared from GTK+ OSD application.

As thee is no stable PHP d-bus bindings, we have written small C library, which wraps these dbus-glib based client into nice API clean interface, which doesn’t expose any d-bus structures, but again here the limitation is that How can we expose the async callback methods which needs to be registered from the PHP.

More on this will come later…stay tuned !!!


~ by triloksoni on February 24, 2008.

3 Responses to “D-BUS PHP Bindings”

  1. Hi,

    How is your project going? I have seen another project: https://sourceforge.net/project/showfiles.php?group_id=17176&package_id=68954

  2. hi, can i communicate with skype from php using dbus?

  3. Is your work available somewhere, I need such a binding myself and it looks stupid to restart from scratch, when you current binding may already do 80% of the work.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: