Bug 45792 - Migrate from dbus-glib to glib's GDBus
Summary: Migrate from dbus-glib to glib's GDBus
Status: RESOLVED FIXED
Alias: None
Product: upower
Classification: Unclassified
Component: general (show other bugs)
Version: unspecified
Hardware: Other All
: medium enhancement
Assignee: Richard Hughes
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-02-08 08:41 UTC by Javier Jardón
Modified: 2015-07-29 12:48 UTC (History)
7 users (show)

See Also:
i915 platform:
i915 features:


Attachments

Description Javier Jardón 2012-02-08 08:41:23 UTC
For GLib 2.26 GDBus D-Bus support was merged, providing an API to replace dbus-glib.

See http://library.gnome.org/devel/gio/stable/gdbus.html and http://developer.gnome.org/gio/stable/ch29.html

According to a quick grep this module seems to use dbus-glib:

configure.ac:PKG_CHECK_MODULES(DBUS_GLIB, [dbus-glib-1 >= 0.76])
libupower-glib/up-client.c:#include <dbus/dbus-glib.h>
libupower-glib/up-device.c:#include <dbus/dbus-glib.h>
libupower-glib/up-wakeups.c:#include <dbus/dbus-glib.h>
src/up-daemon.c:#include <dbus/dbus-glib.h>
src/up-daemon.c:#include <dbus/dbus-glib-lowlevel.h>
src/up-daemon.h:#include <dbus/dbus-glib.h>
src/up-device.c:#include <dbus/dbus-glib.h>
src/up-device.c:#include <dbus/dbus-glib-lowlevel.h>
src/up-device.h:#include <dbus/dbus-glib.h>
src/up-kbd-backlight.c:#include <dbus/dbus-glib.h>
src/up-kbd-backlight.c:#include <dbus/dbus-glib-lowlevel.h>
src/up-kbd-backlight.h:#include <dbus/dbus-glib.h>
src/up-main.c:#include <dbus/dbus-glib.h>
src/up-main.c:#include <dbus/dbus-glib-lowlevel.h>
src/up-polkit.c:#include <dbus/dbus-glib.h>
src/up-polkit.c:#include <dbus/dbus-glib-lowlevel.h>
src/up-qos.c:#include <dbus/dbus-glib.h>
src/up-qos.c:#include <dbus/dbus-glib-lowlevel.h>
src/up-qos.h:#include <dbus/dbus-glib.h>
src/up-wakeups.c:#include <dbus/dbus-glib.h>
src/up-wakeups.h:#include <dbus/dbus-glib.h>
Comment 1 Bastien Nocera 2013-10-14 07:08:01 UTC
That's done in the helper library. There are no plans to do this to the daemon unless absolutely necessary as it's quite invasive for not much gain.
Comment 2 Bastien Nocera 2013-10-14 09:15:07 UTC
The libupower-glib GDBus port is pushed to master. Leaving as NEW for people interested in contributing a GDBus port of the daemon.
Comment 3 Cosimo Cecchi 2015-06-01 17:28:01 UTC
I gave that a shot in this branch: https://github.com/cosimoc/upower/commits/wip/cosimoc/gdbus-daemon

(I don't have enough privileges to publish the branch on git.fd.o).
Comment 4 Richard Hughes 2015-06-02 09:42:36 UTC
Cosimo, that looks great. Is this complete and tested enough to merge to master? I'm happy to fix up any small style issues when merging.
Comment 5 Bastien Nocera 2015-06-02 09:44:29 UTC
(In reply to Richard Hughes from comment #4)
> Cosimo, that looks great. Is this complete and tested enough to merge to
> master? I'm happy to fix up any small style issues when merging.

The trick would be, that, after installing umockdev, that the test suite should pass.
Comment 6 Cosimo Cecchi 2015-06-07 01:33:09 UTC
Yes the port is complete and test suite passes; I also tested it by running it manually on my laptop and couldn't find any obvious problems.
Comment 7 Cosimo Cecchi 2015-07-10 06:18:03 UTC
Any news on this one?
Comment 8 Richard Hughes 2015-07-29 12:48:23 UTC
I've pushed this to master; thanks!


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.