Comment 49 for bug 899858

Revision history for this message
Eric Miao (eric.y.miao) wrote :

Checked with daemon/Makefile.am, obexftp is special because of a different linkage below:

  gvfsd_obexftp_LDADD = $(OBEXFTP_LIBS) $(EXPAT_LIBS) $(libraries)
  if USE_HAL
  gvfsd_obexftp_LDADD += $(HAL_LIBS)
  endif

After configuration, OBEXFTP_LIBS is

  OBEXFTP_LIBS = -ldbus-glib-1 -ldbus-1 -lpthread -lrt -lgobject-2.0 -lglib-2.0 -lbluetooth

So apparently libdbus-glib-1 has the priority to be linked first, and all invocations of the dbus-glib functions call into the system wide library firstly.

libgvfsdaemon.so doesn't not link to dbus-glib-1, but links to the local dbus-gmain.c, which means some other calls into libgvfsdaemon.so could end up calling the functions in dbus-gmain.c, which creates a more complicated mixture.

At this moment, and considering the upstream is working on a solution, I believe a quicker way would be to make libgvfsdaemon statically linked.