[kdepim-users] chatty akonadi apps
Kevin Krammer
krammer at kde.org
Sat Nov 8 16:49:16 GMT 2014
On Saturday, 2014-11-08, 17:31:56, René J.V. Bertin wrote:
> On Saturday November 08 2014 16:45:09 Kevin Krammer wrote:
> >Right.
> >Since this is Akonadiserver, it currently uses unconfigurable log since
> >that was not available in Qt4.
> >
> >It can be built without that though.
>
> How? Why is that not a setting that can be controlled through
> akonadiserverrc?
Code wise this looks like that:
#ifndef QT_NO_DEBUG_OUTPUT
QDebug akDebug();
#else
inline QNoDebug akDebug() {
return QNoDebug();
}
#endif
Basically the same thing Qt is doing for qDebug().
Configurable logging requires some infrastructure, e.g. centrally accessible
settings, which have not been available in Qt4 but are in Qt5.
One could potentially patch Akonadi Server with something primitive like a
global variable, but that is unlikely to be accepted into the upstream code
base.
The compile time switch is mostly there to have debug logging in developer
builds and disable it in production builds (this has the advantage of not
incurring any overhead).
Not entirely sure why it is built with that enabled when packages by
distributions.
Cheers,
Kevin
--
Kevin Krammer, KDE developer, xdg-utils developer
KDE user support, developer mentoring
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 173 bytes
Desc: This is a digitally signed message part.
URL: <http://mail.kde.org/pipermail/kdepim-users/attachments/20141108/3cb77c0a/attachment.sig>
-------------- next part --------------
_______________________________________________
KDE PIM users mailing list
Subscription management: https://mail.kde.org/mailman/listinfo/kdepim-users
More information about the kdepim-users
mailing list