Skip navigation.
KDE Developer's Journals

Why do good people do bad things?

njaard's picture

arkimedes:~# apt-get install dbus-qt-1-dev
(stuff skipped)
The following NEW packages will be installed:
  dbus-qt-1-dev dbus-qt-1c2 hicolor-icon-theme kdelibs-bin kdelibs-data
  kdelibs4c2 libarts1c2 libaspell15 libfam0 libjasper-1.701-1 libnetpbm10
  libopenexr2c2 menu-xdg netpbm
0 upgraded, 14 newly installed, 0 to remove and 2 not upgraded.
Need to get 19.9MB/21.0MB of archives.
After unpacking 69.5MB of additional disk space will be used.
Do you want to continue [Y/n]?

Ok, I have to investigate. Why does DBUS's Qt bindings want to link to all of Qt?

So I grab the DBUS source code, compile it, do an ldd libdbus-qt-1.so -- to my dismay, it links to libkdecore.so! What gives?

So, upon further investigation into the DBUS build system, I find, much my dismay, the following:

dnl linking to kdecore will give us a bit of help from libtool
if (! kde-config >& /dev/null); then
    have_qt=no
else
    kdelibs=`kde-config --install lib --expandvars 2>/dev/null`
    if test -z $kdelibs -o ! -f $kdelibs/libkdecore.la; then
        have_qt=no
    else
        DBUS_QT_LIBS="$kdelibs/libkdecore.la"
    fi
fi

Brilliant. They link to KDE just because KDE links to Qt, and they need Qt. Sheer brilliance. I'm impressed.

(it should be noted that the cvs version of DBUS doesn't have this problem).

So, I submitted a patch to the Debian maintainers (as that's the distribution I use). I'm sure they'll reject it, as they always do.

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
daniels's picture

> So, I submitted a patch to

> So, I submitted a patch to the Debian maintainers (as that's the distribution I use). I'm sure they'll reject it, as they always do.

Do you want to back that statement up?

njaard's picture

this patch hasn't been

this patch hasn't been applied yet, for one.

daniels's picture

Yes, and the bug report is

Yes, and the bug report is seventeen days old. I think you'll note that there hasn't been an upload in that time, either. So, no, it hasn't been applied yet, and yes, it probably will, but I can tell you now that this entry provides absolutely no motivation whatsoever to do so. Thanks for making the day of this D-BUS maintainer so much brighter.

sam hocevar's picture

It hasn’t been rejected,

It hasn’t been rejected, though, so you haven’t yet backed up your assertion that patches sent to Debian developers are always rejected.

However, you are right that your patch will probably be rejected. Since you seem to be implying that upstream’s CVS does not have the problem, it would make more sense to use a fix from upstream rather than your hack.

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.