PDA

View Full Version : Can't see container contents, QStrings when debugging



MattPhillips
9th October 2011, 16:52
I've used many different versions of Qt over the years and this is a first. Debugging in QtCreator 2.3.1 with gdb 7.3.1, debugging works great except that when I'm in the 'Locals and Expressions' tab I can't see the internal data of Qt or STL containers, just the address of the data segment. I got a suggestion from SO to be sure to rebuild the debugger helper, but But Tools -> Options -> Qt4 has 'Not Needed' next to GDB Helper. I'm using Qt 4.7.3. Anyone know how I can make it so I can see container contents again?

winkle98
13th October 2011, 00:32
I'm hoping someone has a solution for this. I just upgraded from QtCreator 2.0.1 to QtCreator 2.3.1. I downloaded the bin updater for 64 bit linux. Also, I'm using 4.6.2 of the Qt SDK ( not something I get to choose or change.) to build my applications. It appeared from the website that the app is still supposed to work with earlier version of QtSDK.

On the up side the I'm getting more debugging information on inhouse data types than I got with 2.0.1. (Which I love and would prefer not to abandon.) However, I'm not getting any of the Qt types. Unfortunately, I'm not getting any information for the Qt objects. The typical... QString is just diaplaying an address problem.

In version 2.0.1 of QtCreator, I could generate the Debugger helpers. But when I look at the Help details it says "Cannot be compiled" for all of the QML sections and "Not needed" for the GDB Helper.

How do I get this turned back on?

Thanks

MattPhillips
8th December 2011, 03:52
So it turns out that the debugging helper for later versions of QtCreator (don't know if it's QtCreator or gdb, but anyway) requires the installation of python developer tools. This may be taken care of with installation defaults in later versions of Ubuntu, but for 10.04
sudo apt-get install python-dev, and subsequently rebuilding gdb, is required.

hill_rg
31st December 2011, 21:35
Total newbie alert!

I am having the same issue with QtSDK 4.7.4 windows install and Windows/MinGW debugging. I tried uninstalling the QtSDK, installing Python 2.7 from http://www.python.org/ and then re-installing QtSDK for windows. I can still run all the examples but I cannot drill into any of the Qt objects.

I found directions for building Python and GDB at http://developer.qt.nokia.com/wiki/QtCreator_Build_Gdb but I am new to this and had difficulties following the instructions - should I persevere or is there another likely solution?

In QtCreator I am running on the SDK install default debugger options - is there something I should be customizing in the options?