PHP and GObject Introspection

GObject Introspection is one of the hidden jewels of the GNOME stack: you write a library in C or Vala, and it becomes automatically available to a wide variety of languages and runtimes, including Python, JavaScript, Java and Qt.

Now I would like to bring GObject Introspection to PHP. Why?

For many years we in the Midgard community have been using GNOME infrastructure on the web server side, by building our persistence layer on top of GObjects, and providing D-Bus notifications when content changes. So far this has been done with our own custom PHP extension.

I believe a common PHP extension providing GObject Introspection support would make more sense, as it wouldn't just benefit our own community, but also support efforts like php-gtk.

Alexey Zakhlestin already started a project for this a while back, but unfortunately has been unable to finish it. Because of this, we would be willing to sponsor anybody interested in making the gobject-for-php extension work.

Benefits for the GNOME community:

  • New supported development language and a large community of potential contributors
  • The possibility of making the GNOME stack relevant in web space. Just think of Telepathy or GStreamer in a web app

Benefits for the PHP community:

  • Access to the rich collection of GNOME libraries, many which may be useful when building web applications
  • Being able to use your PHP skills to build GNOME applications and bring them to interesting environments like Ubuntu and Cordia

Benefits for the Midgard community:

  • No need to maintain our own custom PHP extension
  • A more generic GObject Introspection extension has better chances of being included into Linux distributions and being available on hosting providers

Let me know if you are interested. We're coming to the Desktop Summit with Piotras, so for example that is a great opportunity to talk more about this.


Read more Midgard posts.