Bug 112343 - Consider porting to gdbus.
Summary: Consider porting to gdbus.
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: LibreOffice (show other bugs)
Version:
(earliest affected)
5.4.1.2 release
Hardware: All Linux (All)
: medium enhancement
Assignee: Not Assigned
URL:
Whiteboard: target:6.1.0 target:6.2.0
Keywords:
Depends on:
Blocks:
 
Reported: 2017-09-12 08:00 UTC by Hussam Al-Tayeb
Modified: 2018-08-30 10:38 UTC (History)
4 users (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Hussam Al-Tayeb 2017-09-12 08:00:58 UTC
libreoffice uses dbus-glib at the moment https://cgit.freedesktop.org/libreoffice/core/tree/configure.ac#n9901
It is one of the very few applications still using dbus-glib.
Please consider porting to gdbus.
https://developer.gnome.org/gio/stable/gdbus.html

Thank you very much.
Comment 1 Jean-Baptiste Faure 2017-09-24 16:56:43 UTC
Set needDevEval keyword.
Comment 2 Buovjaga 2017-10-29 19:25:35 UTC
It seems GDBus is used in some places: https://cgit.freedesktop.org/libreoffice/core/commit/?id=2a593ff092c628eff906c4df9b4da993a3973ec3
Comment 3 Xisco Faulí 2018-01-08 10:52:44 UTC
(In reply to Buovjaga from comment #2)
> It seems GDBus is used in some places:
> https://cgit.freedesktop.org/libreoffice/core/commit/
> ?id=2a593ff092c628eff906c4df9b4da993a3973ec3

@Samuel, do you have any insight here?
Comment 4 Samuel Mehrbrodt (allotropia) 2018-01-08 13:15:13 UTC
Yes, existing usages of dbus-glib should be ported over to gdbus.
There is also a UNO Api wrapper for that, which should be used. See https://cgit.freedesktop.org/libreoffice/core/commit/?id=91d361604781f92640c9727add1e08cde854037e
Comment 5 Arkadiy Illarionov 2018-01-20 09:39:41 UTC
Hi,
I'd like to work on this bug.
Is there any tests for DBus in source tree? How can I test my changes?
Comment 6 Samuel Mehrbrodt (allotropia) 2018-01-22 09:16:46 UTC
(In reply to Arkadiy Illarionov from comment #5)
> Hi,
> I'd like to work on this bug.
> Is there any tests for DBus in source tree? How can I test my changes?

I'm not aware of any tests. You need to find a way to trigger the code path.
If you need help with that, you might better ask in IRC.
Comment 7 Commit Notification 2018-03-26 09:04:03 UTC
Arkadiy Illarionov committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=fc3e31ff8eaff7385e200f82972c4e5eb9055723

tdf#112343 Port ScreenSaverInhibitor to GDBus

It will be available in 6.1.0.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 8 Arkadiy Illarionov 2018-03-26 17:40:21 UTC
As I understand, ScreenSaverInhibitor was last user of dbus-glib and check for DBus support (https://opengrok.libreoffice.org/xref/core/configure.ac#9955) can be changed from 
PKG_CHECK_MODULES(DBUS, dbus-glib-1 >= 0.70)
to 
PKG_CHECK_MODULES(DBUS, dbus-1 >= 0.60)

However some modules, e.g. sd/source/ui/remotecontrol/BluetoothServer.cxx, use dbus and glib, so proposed change breaks build of these modules.

I believe fixing this is more or less simple for somebody familiar with build system.
Comment 9 Samuel Mehrbrodt (allotropia) 2018-03-27 06:31:23 UTC
(In reply to Arkadiy Illarionov from comment #8)
> As I understand, ScreenSaverInhibitor was last user of dbus-glib and check
> for DBus support
> (https://opengrok.libreoffice.org/xref/core/configure.ac#9955) can be
> changed from 
> PKG_CHECK_MODULES(DBUS, dbus-glib-1 >= 0.70)
> to 
> PKG_CHECK_MODULES(DBUS, dbus-1 >= 0.60)
> 
> However some modules, e.g. sd/source/ui/remotecontrol/BluetoothServer.cxx,
> use dbus and glib, so proposed change breaks build of these modules.
> 
> I believe fixing this is more or less simple for somebody familiar with
> build system.

Can you port the BluetoothServer.cxx module also over?
Comment 10 Arkadiy Illarionov 2018-03-27 18:28:10 UTC
(In reply to Samuel Mehrbrodt (CIB) from comment #9)
> (In reply to Arkadiy Illarionov from comment #8)
> > As I understand, ScreenSaverInhibitor was last user of dbus-glib and check
> > for DBus support
> > (https://opengrok.libreoffice.org/xref/core/configure.ac#9955) can be
> > changed from 
> > PKG_CHECK_MODULES(DBUS, dbus-glib-1 >= 0.70)
> > to 
> > PKG_CHECK_MODULES(DBUS, dbus-1 >= 0.60)
> > 
> > However some modules, e.g. sd/source/ui/remotecontrol/BluetoothServer.cxx,
> > use dbus and glib, so proposed change breaks build of these modules.
> > 
> > I believe fixing this is more or less simple for somebody familiar with
> > build system.
> 
> Can you port the BluetoothServer.cxx module also over?

I'm not sure I can do this. At least I couldn't find DBus -> GDBus API comparison similar to https://developer.gnome.org/gio/stable/ch35s02.html.
Comment 11 Arkadiy Illarionov 2018-07-30 05:15:23 UTC
Hi,
I've made patch for this issue: https://gerrit.libreoffice.org/#/c/57157/
Can anybody review it?
Comment 12 Commit Notification 2018-08-08 10:46:22 UTC
Arkadiy Illarionov committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=02addb3618f026acd72ece76fc726b9473cc5940

tdf#112343 Change dependency from dbus-glib to dbus

It will be available in 6.2.0.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 13 Commit Notification 2018-08-12 20:34:39 UTC
Arkadiy Illarionov committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=f465685aecf508be987ae199e77667af896a5e8f

Resolves: tdf#112343 remove last dbus-glib mentions

It will be available in 6.2.0.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 14 Xisco Faulí 2018-08-30 10:38:01 UTC
Fito, why has it been moved back to NEW without giving any explanation?
Putting it back to RESOLVED FIXED