Where I can find gdb pretty printers for qt5?

I could find only for qt4 on kde developer site. Maybe somebody knows whether pretty printers for new version of Qt exist and where I can find them.

I know that it's possible to use latest version of QtCreator, but I need just plain python scripts for GDB.

share|improve this question

The pretty printers listed on https://techbase.kde.org/Development/Tutorials/Debugging/Debugging_with_GDB are only partially compatible with Qt 5. Some types (such a QByteArray) are not handled correctly.

Alex Merry has worked on Qt 5 pretty printers and tried to push these into the Qt5 Base packages (unfortunately it did not made it). For convenience, I have made his printers available at https://github.com/Lekensteyn/qt5printers

share|improve this answer
    
What version of gdb is required to use github.com/Lekensteyn/qt5printers ? when I try to use it on GNU gdb (GDB) Red Hat Enterprise Linux (7.2-75.el6) I get Traceback (most recent call last): File "<string>", line 3, in <module> File "/home/myusername/gdb/printers/qt5printers/__init__.py", line 42, in <module> import gdb.printing ImportError: No module named printing – bgoodr Mar 3 '17 at 3:57
    
@bgoodr You need at least GDB 7.3 for the pretty printing module (sourceware.org/git/…, see also the NEWS file) – Lekensteyn Mar 3 '17 at 23:31

for reference, the following supports qt5 objects (inspite of its name), and appears to be periodically updated

https://cgit.kde.org/kdevelop.git/tree/debuggers/gdb/printers

share|improve this answer

As far as I know pretty printers are located here: http://gcc.gnu.org/svn/gcc/trunk/libstdc++-v3/python/

Also, GDB binaries with Python enabled can be found here. http://origin.releases.qt-project.org/gdb/

share|improve this answer
2  
Those pretty printers are for libstdc++. The question was about pretty printers for Qt5 – ar31 Feb 19 '13 at 15:10

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.