Skip to content
Sep 14 / Danushka

Qt Creator Debugger Not Displaying QString

So on MacOS Qt Creator’s debugger (Qt 4.6) has been driving me nuts because for some reason it refused to display QString’s and other known internal types properly.

After hunting around I found this bug report which refers to the 2010.04 SDK which is the one I have installed. The dylib with the gdb extensions that ships with this SDK is broken, but it’s amazingly simple to fix because Qt Creator allows you to rebuild the dylib from the preference panel with one click (now thats a totally new height in open source software!).

  1. sudo rm /usr/local/Qt4.6/qtc-debugging-helper/libgdbmacros.dylib
  2. Start Qt Creator
  3. Qt Creator -> Preferences -> Select the “Qt” tab -> Select “Qt in PATH” under “Auto-detect”
  4. There should be a red cross next to the label “Debugging Helper.” On the right of that there’s a rebuild button – hit it and wait.
  5. The red cross should turn into a green tick.
  6. Clean & Build your project.

More Reading: Bug report with the official solution: QTCREATORBUG-1799

2 Comments

leave a comment
  1. Mark / Dec 4 2011

    I have this problem and this solution dies at step 3. I don’t have a “Qt in PATH” under “Auto-detect” (nor under “Auto-detected”.

    Technically it actually dies at step 1 since there is no libgdbmacros.dylib on my system at that location or anywhere else.

  2. Danushka / Dec 7 2011

    Hi Mark, this was only meant to be used for 2010.04 version of SDK under OSX, YMMV for other versions. I did have a situation where the libgdbmacros.dylib was located INSIDE the QtCreator.app/ package folder, it may pay to fire a quick “find” command under that and look for all *.dylibs instead of the precise name above. Good Luck.

Leave a Comment