• Stars
    star
    132
  • Rank 274,205 (Top 6 %)
  • Language
    Python
  • Created over 9 years ago
  • Updated about 5 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

GDB Pretty printers for Qt5

qt5printers

The core.py, typeinfo.py and __init__.py files are taken from patchset 2 at https://codereview.qt-project.org/87052 and provide a GDB pretty printer for Qt5. These are authored by Alex Merry from the KDE project.

Usage

Copy the three Python files to ~/.gdb/qt5printers/ and add this to your ~/.gdbinit (or execute it from an existing gdb session):

python
import sys, os.path
sys.path.insert(0, os.path.expanduser('~/.gdb'))
import qt5printers
qt5printers.register_printers(gdb.current_objfile())
end

Now verify it with your favorite program. Below you can find a quick test program.

Test program

Here is a test program (save it as test.cpp):

#include <QTextStream>
void test(const QByteArray & ba) { }
int main(void) {
    test(QByteArray("abc"));
    return 0;
}

Compile it with:

g++ test.cpp $(pkg-config --cflags --libs Qt5Core) -g

If everything goes well you should see the expanded data:

$ gdb -q -ex break\ test -ex r ./a.out
...
Breakpoint 1, test (ba="abc" = {...}) at test.cpp:4
4           test(QByteArray("abc"));

Background

The Qt4 pretty printers from KDevelop0 are not fully compatible with Qt5. For instance, the latest version (from December 2014) does not properly handle QByteArray. While these qt5printers are compatible with Qt5, it conflicts with Qt4 (for example, QByteArray changed in Qt 5 from Qt 4 in this commit1).

See also:

License

For the applicable licenses, see the headers of the files and refer to the Qt5 sources at https://code.qt.io/cgit/qt/qtbase.git/tree/.

More Repositories

1

apk-downloader

APK Downloader Chrome Extension
JavaScript
321
star
2

pacemaker

Heartbleed (CVE-2014-0160) client exploit
Python
319
star
3

dmg2img

DMG2IMG allows you to convert a (compressed) Apple Disk Images (imported from http://vu1tur.eu.org/dmg2img). Note: the master branch contains imported code, but lacks bugfixes/features from the develop branch. "develop" branch is recommended!
C
178
star
4

ltunify

Tool for working with Logitech Unifying receivers and devices (mirror)
C
166
star
5

lglaf

LG Download Mode utility and documentation
Python
137
star
6

acpi-stuff

Tools for analysing ACPI DSDT/SSDT tables and notes
HTML
54
star
7

netns

Network Namespace management for Linux
Shell
48
star
8

wireguard-dissector

Wireshark dissector (written in Lua) for dissecting the WireGuard tunneling protocol.
Lua
46
star
9

luagcrypt

luagcrypt is a Lua interface to the libgcrypt library, written in C.
C
26
star
10

parse8xp

Convert between source code and TI83/TI84/TI84+/TI84s programs (in .8xp format)
Python
22
star
11

kdnet

Windows Kernel Debugger over Network (Wireshark dissector and maybe more)
Lua
20
star
12

el4000

Energy Logger 4000 utility
Python
16
star
13

clang-alloc-free-checker

Clang static analyzer plugin for checking memory issues in Wireshark/GLib applications (allocator mismatch and memleaks)
C++
14
star
14

make-gapps-zip

Documentation and tools for reproducible update.zip builds
Python
12
star
15

lua-unicode

Patched Lua library to add UTF-8 support on Windows.
CMake
12
star
16

windows-bootstrap

Scripts and tools to automate a Windows 7 installation for QEMU
PowerShell
11
star
17

hex-viewer

Hex viewer for modern browsers with bit annotation functionality
JavaScript
10
star
18

ssh-blocker

Block IP addresses based on SSH logs
C
10
star
19

noscript-nsa

NSA - NoScript Anywhere (Firefox Mobile add-on)
JavaScript
8
star
20

wireshark-fuzztools

Tools to assist in fuzzing (or triaging from oss-fuzz)
Python
7
star
21

chromium-quic

Subset of chromium repo: net/quic/ net/tools/quic/ net/third_party/quic/
C++
7
star
22

aur

Personal PKGBUILDs, from AUR and official repositories
Shell
4
star
23

rsyncbackup

Simple interface for encrypted offline backups with snapshots support
Shell
3
star
24

archdir

Bootstrap a QEMU/KVM VM for building Arch Linux packages
Shell
3
star
25

dnsallow

dnsallow enables whitelisting of IP addresses based on DNS responses.
C
3
star
26

wireshark-ansible

ansible configuration for setting up a gerrit + buildbot nine cluster
Python
3
star
27

qemu-tools

Miscellaneous tools related to QEMU
Python
2
star
28

pystubgen

Generates Python source code from a module for documentation purposes
Python
2
star
29

wgll

Low-level prototyping tool for WireGuard
Python
2
star
30

ls-l.info

Test domain
HTML
1
star
31

iot19-leshan

Practical assignment for the TU/e 2017 course on IoT (2IMN15) - Group 19
Java
1
star