[SailfishDevel] how to get qml debug output to file
Andrey Kozhevnikov
coderusinbox at gmail.com
Mon Feb 24 07:00:42 UTC 2014
working fine for both cpp and qml output
On 24.02.2014 05:37, Artem Marchenko wrote:
> I found message handler working just fine (both for QML console and
> cpp qDebug() messages) is emulator builds, but not for when code is
> running on device. Go figure.
>
> Could it be so that on device exactly QML engine is somehow always
> used separately from your c++ execution context.. no it doesn't make
> sense.
>
> It would be nice to have some logs-to-file way working in production
> with both QML and c++ logs indeed.
>
> Cheers,
> Artem.
>
>
>
> On Wed, Feb 5, 2014 at 4:58 PM, Robin Burchell
> <robin.burchell at jolla.com <mailto:robin.burchell at jolla.com>> wrote:
>
> On 04 Feb 2014, at 22:37, Tero Siironen <tero.siironen at iki.fi
> <mailto:tero.siironen at iki.fi>> wrote:
> > Andrey Kozhevnikov <coderusinbox at gmail.com
> <mailto:coderusinbox at gmail.com>> kirjoitti 4.2.2014 kello 23.14:
> >
> >> This is messages handler i'm using in my projects:
> >
> >
> > This doesn't seem to make a difference for me, the log file
> still contains only c++ side debug prints, qml prints (like
> console.log()) are not handled with messagehandler.
> >
> > Actually I found out that even if set in pro-file:
> > DEFINES +=QT_NO_DEBUG_OUTPUT
> > DEFINES +=QT_NO_WARNING_OUTPUT
> >
> > I still get qml debug prints printed out to console, so it seems
> that those prints from qml are not handled via normal debug
> handling at all?
> >
> > I would like to get no debug printing at all, or then just to file.
>
> DEFINES in qmake adds additional defines (-D) to the cflags used
> to build C++ affect code compiled with them. QtDeclarative was not
> compiled with these defines, so your adding them won't affect
> console.log (whose C++ implementation lives inside QtDeclarative).
>
> If you don't want debug prints, you need to install a message
> handler (you say you've tried this and it doesn't work, I can't
> answer why that would be the case, it should work, as it uses the
> same infrastructure).
>
> BR,
> Robin
> _______________________________________________
> SailfishOS.org Devel mailing list
>
>
>
>
> --
> Artem Marchenko
> http://agilesoftwaredevelopment.com
> http://twitter.com/AgileArtem
>
>
> _______________________________________________
> SailfishOS.org Devel mailing list
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.sailfishos.org/pipermail/devel/attachments/20140224/6567bc2a/attachment.html>
More information about the Devel
mailing list