[Qt-creator] GDB error with Qt creator

Spandan Sharma ustulation at gmail.com
Tue Nov 19 13:03:06 CET 2013


I am not being able to debug my c++ code because the debugger shows the
error message saying it quit unexpectedly with error code 1. What is the
way out?

Config:
Qt Creator: 2.7.2 (based on Qt 5.1.0 - 64 bit)
Qt 5.1.0
OS: Mac
Compiler: Clang 3.2

*Debugger log messages:*

sStarting debugger "QmlCppEngine" for ABI
"x86-macos-generic-mach_o-64bit"...

dStart parameters: 'gui' mode: 1

dABI: x86-macos-generic-mach_o-64bit

dLanguages: c++ qml

dExecutable:
/Users/folsom/Saurabh/software/UI_ROOT/trunk/source/gui/gui.app/Contents/MacOS/gui
-qmljsdebugger=port:3768,block

dDirectory:
/Users/folsom/Saurabh/software/UI_ROOT/trunk/source/gui/gui.app/Contents/MacOS

dDebugger: /usr/bin/gdb

dProject: /Users/folsom/Saurabh/software/UI_ROOT/trunk/source (built:
/Users/folsom/Saurabh/software/UI_ROOT/trunk/source)

dQML server: 127.0.0.1:3768

dRemote: :0

dSysroot:

dDebug Source Location:
/usr/src/debug/qt5base/src/corelib:/usr/src/debug/qt5base/src/gui:/usr/src/debug/qt5base/src/network:/usr/src/debug/qt5base/src/v8:/usr/src/debug/qt5declarative/src/qml

dSymbol file:

dDumper libraries:
/Users/folsom/Qt5.1.0//5.1.0/clang_64//qtc-debugging-helper/libdumper.dylib
/Users/folsom/Qt5.1.0//5.1.0/clang_64//qtc-debugging-helper/
/Users/folsom/Qt5.1.0/Qt
Creator.app/Contents/qtc-debugging-helper/3765330530/
/Users/folsom/Library/Application
Support/QtProject/QtCreator/qtc-debugging-helper/3765330530/

dDebugger settings:

dUseToolTipsInBreakpointsView: false (default: false)

dUseToolTipsInLocalsView: false (default: false)

dUseToolTips: false (default: false)

dLoadGdbInit: true (default: true)

dUseAddressInStackView: false (default: false)

dUseAddressInBreakpointsView: false (default: false)

dBreakpointsFullPath: false (default: false)

dSwitchModeOnExit: false (default: false)

dCloseBuffersOnExit: false (default: false)

dShowThreadNames: false (default: false)

dUseCodeModel: true (default: true)

dUseDebuggingHelper: false (default: true) ***

dRaiseOnInterrupt: true (default: true)

dUseMessageBoxForSignals: true (default: true)

dFontSizeFollowsEditor: false (default: false)

dUseAlternatingRowColours: false (default: false)

dVerboseLog: false (default: false)

dLogTimeStamps: false (default: false)

dQmlInspector.FromQml: false (default: false)

dQmlInspector.ShowAppOnTop: false (default: false)

dAutoQuit: false (default: false)

dAlwaysAdjustRegistersColumnWidths: false (default: false)

dBreakOnAbort: false (default: false)

dBreakOnFatal: false (default: false)

dBreakOnWarning: false (default: false)

dShowQmlObjectTree: true (default: true)

dAlwaysAdjustModulesColumnWidths: false (default: false)

dAlwaysAdjustThreadsColumnWidths: false (default: false)

dAlwaysAdjustSnapshotsColumnWidths: false (default: false)

dAlwaysAdjustBreakpointsColumnWidths: false (default: false)

dAdjustBreakpointLocations: true (default: true)

dSelectedPluginBreakpoints: false (default: false)

dAllPluginBreakpoints: true (default: true)

dBreakOnCatch: false (default: false)

dBreakOnThrow: false (default: false)

dSelectedPluginBreakpointsPattern: .* (default: .*)

dNoPluginBreakpoints: false (default: false)

dMaximalStringLength: 10000 (default: 10000)

dAlwaysAdjustLocalsColumnWidths: false (default: false)

dAutoDerefPointers: true (default: true)

dSortStructMembers: true (default: true)

dEnableReverseDebugging: false (default: false)

dSkipKnownFrames: false (default: false)

dListSourceFiles: false (default: false)

dMaximalStackDepth: 20 (default: 20)

dIntelFlavor: false (default: false)

dMultiInferior: false (default: false)

dShowQtNamespace: true (default: true)

dShowStandardNamespace: true (default: true)

dAlwaysAdjustStackColumnWidths: false (default: false)

dWatchdogTimeout: 60 (default: 20) ***

dGdbPostAttachCommands: (default: )

dGdbStartupCommands: (default: )

dAttemptQuickStart: false (default: false)

dWarnOnReleaseBuilds: true (default: true)

dTargetAsync: false (default: false)

dUseDynamicType: true (default: true)

dAutoEnrichParameters: false (default: true) ***

dState changed from DebuggerNotReady(0) to EngineSetupRequested(1) [master]

dQUEUE: SETUP ENGINE

dCALL: SETUP ENGINE

dState changed from DebuggerNotReady(0) to EngineSetupRequested(1)

dQUEUE: SETUP ENGINE

dState changed from DebuggerNotReady(0) to EngineSetupRequested(1)

dQUEUE: SETUP ENGINE

dCALL: SETUP ENGINE

dNOTE: ENGINE SETUP OK

dState changed from EngineSetupRequested(1) to EngineSetupOk(3)

dQUEUE: SETUP INFERIOR

dCALL: SETUP ENGINE

dTRYING TO START ADAPTER

dENABLING TEST CASE: 0

dSTARTING /usr/bin/gdb -i mi
--tty=/var/folders/6q/532jg7t97m3c6lrkbx9n27km0000gn/T/QtCreator.Q16831

dGDB STARTED, INITIALIZING IT

<1show version

<2show debug-file-directory

<3set print object on

<4set breakpoint pending on

<5set print elements 10000

<6set overload-resolution off

<7handle SIGSEGV nopass stop print

<8set unwindonsignal on

<9set width 0

<10set height 0

<11-interpreter-exec console "set remotecache on"

<12-interpreter-exec console "maintenance set internal-warning quit no"

<13-interpreter-exec console "maintenance set internal-error quit no"

dTHE FOLLOWING COMMAND CHECKS AVAILABLE FEATURES. AN ERROR IS EXPECTED.

<14-interpreter-exec console "disassemble 0 0"

dEXAMINING
/Users/folsom/Saurabh/software/UI_ROOT/trunk/source/gui/gui.app/Contents/MacOS/gui

dELF SECTIONS:

dERROR WHILE READING ELF SECTIONS:
'/Users/folsom/Saurabh/software/UI_ROOT/trunk/source/gui/gui.app/Contents/MacOS/gui'
is not an ELF object

sSetting up inferior...

<15directory /usr/src/debug/qt5base/src/corelib

<16directory /usr/src/debug/qt5base/src/gui

<17directory /usr/src/debug/qt5base/src/network

<18directory /usr/src/debug/qt5base/src/v8

<19directory /usr/src/debug/qt5declarative/src/qml

<20-interpreter-exec console "set auto-solib-add on"

<21-interpreter-exec console "python print 43"

<22-interpreter-exec console "pwd"



>~"GNU gdb 6.3.50-20050815 (Apple version gdb-1824) (Wed Feb 6 22:51:23 UTC
2013)\n"

>~"Copyright 2004 Free Software Foundation, Inc.\n"

>~"GDB is free software, covered by the GNU General Public License, and you
are\n"

>~"welcome to change it and/or distribute copies of it under certain
conditions.\n"

>~"Type \"show copying\" to see the conditions.\n"

>~"There is absolutely no warranty for GDB. Type \"show warranty\" for
details.\n"

>~"This GDB was configured as \"x86_64-apple-darwin\"."

>~"\n"



>&"show version\n"

>~"GNU gdb 6.3.50-20050815 (Apple version gdb-1824) (Wed Feb 6 22:51:23 UTC
2013)\n"

>~"Copyright 2004 Free Software Foundation, Inc.\n"

>~"GDB is free software, covered by the GNU General Public License, and you
are\n"

>~"welcome to change it and/or distribute copies of it under certain
conditions.\n"

>~"Type \"show copying\" to see the conditions.\n"

>~"There is absolutely no warranty for GDB. Type \"show warranty\" for
details.\n"

>~"This GDB was configured as \"x86_64-apple-darwin\".\n"

>1^done

dPARSING VERSION: 1^done

dSUPPORTED GDB VERSION GNU gdb 6.3.50-20050815 (Apple version gdb-1824)
(Wed Feb 6 22:51:23 UTC 2013)

dCopyright 2004 Free Software Foundation, Inc.

dGDB is free software, covered by the GNU General Public License, and you
are

dwelcome to change it and/or distribute copies of it under certain
conditions.

dType "show copying" to see the conditions.

dThere is absolutely no warranty for GDB. Type "show warranty" for details.

dThis GDB was configured as "x86_64-apple-darwin".

dGNU gdb 6.3.50-20050815 (Apple version gdb-1824) (Wed Feb 6 22:51:23 UTC
2013)

dCopyright 2004 Free Software Foundation, Inc.

dGDB is free software, covered by the GNU General Public License, and you
are

dwelcome to change it and/or distribute copies of it under certain
conditions.

dType "show copying" to see the conditions.

dThere is absolutely no warranty for GDB. Type "show warranty" for details.

dThis GDB was configured as "x86_64-apple-darwin".

dUSING GDB VERSION: 60350, BUILD: 1824 (APPLE)

<23-interpreter-exec console "set target-async off"

<24-interpreter-exec console "set build-id-verbose 2"



>&"show debug-file-directory\n"

>2^done,value="/usr/local/lib/debug"



>&"set print object on\n"

>3^done



>&"set breakpoint pending on\n"

>4^done



>&"set print elements 10000\n"

>5^done



>&"set overload-resolution off\n"

>6^done



>&"handle SIGSEGV nopass stop print\n"

>7^done



>&"set unwindonsignal on\n"

>8^done



>&"set width 0\n"

>9^done



>&"set height 0\n"

>10^done



>11^done,time={wallclock="0.00041",user="0.00002",system="0.00039",start="1384860945.763441",end="1384860945.763850"}



dUNEXPECTED GDB STDERR: Undefined maintenance set command:
"internal-warning quit no". Try "help maintenance set".

>12^error,msg="Undefined maintenance set command: \"internal-warning quit
no\". Try \"help maintenance set\"."



>13^error,msg="Undefined maintenance set command: \"internal-error quit
no\". Try \"help maintenance set\"."



dUNEXPECTED GDB STDERR: Undefined maintenance set command: "internal-error
quit no". Try "help maintenance set".

>Dump of assembler code from 0x0 to 0x0:

>End of assembler dump.

>14^done,time={wallclock="0.00222",user="0.00004",system="0.00218",start="1384860945.764215",end="1384860945.766439"}



>&"directory /usr/src/debug/qt5base/src/corelib\n"

>&"Warning: /usr/src/debug/qt5base/src/corelib: No such file or
directory.\n"

>15^done



>&"directory /usr/src/debug/qt5base/src/gui\n"

>&"Warning: /usr/src/debug/qt5base/src/gui: No such file or directory.\n"

>16^done



>&"directory /usr/src/debug/qt5base/src/network\n"

>&"Warning: /usr/src/debug/qt5base/src/network: No such file or
directory.\n"

>17^done



>&"directory /usr/src/debug/qt5base/src/v8\n"

>&"Warning: /usr/src/debug/qt5base/src/v8: No such file or directory.\n"

>18^done



>&"directory /usr/src/debug/qt5declarative/src/qml\n"

>&"Warning: /usr/src/debug/qt5declarative/src/qml: No such file or
directory.\n"

>19^done



>20^done,time={wallclock="0.00001",user="0.00001",system="0.00000",start="1384860945.767073",end="1384860945.767087"}



dUNEXPECTED GDB STDERR: Undefined command: "python". Try "help".

>21^error,msg="Undefined command: \"python\". Try \"help\"."



>Working directory
/Users/folsom/Saurabh/software/UI_ROOT/trunk/source/gui/gui.app/Contents/MacOS.

>22^done,time={wallclock="0.00005",user="0.00001",system="0.00003",start="1384860945.767189",end="1384860945.767235"}

dENGINE SUCCESSFULLY STARTED

dNOTE: ENGINE SETUP OK

dState changed from EngineSetupRequested(1) to EngineSetupOk(3)

dNOTE: ENGINE SETUP OK

dState changed from EngineSetupRequested(1) to EngineSetupOk(3) [master]

dQUEUE: SETUP INFERIOR

dState changed from EngineSetupOk(3) to InferiorSetupRequested(4) [master]

dQUEUE: SETUP INFERIOR

dQUEUE: SETUP INFERIOR



dCALL: SETUP INFERIOR

dState changed from EngineSetupOk(3) to InferiorSetupRequested(4)

dQUEUE: SETUP INFERIOR

dState changed from EngineSetupOk(3) to InferiorSetupRequested(4)

dQUEUE: SETUP INFERIOR

dCALL: SETUP INFERIOR

dNOTE: INFERIOR SETUP OK

dState changed from InferiorSetupRequested(4) to InferiorSetupOk(6)

dCALL: SETUP INFERIOR

<25-exec-arguments -qmljsdebugger=port:3768,block

<26-file-exec-and-symbols
"/Users/folsom/Saurabh/software/UI_ROOT/trunk/source/gui/gui.app/Contents/MacOS/gui"

dUNEXPECTED GDB STDERR: No symbol table is loaded. Use the "file" command.

dNo symbol table is loaded. Use the "file" command.

>23^error,msg="No symbol table is loaded. Use the \"file\" command."



>24^error,msg="No symbol table is loaded. Use the \"file\" command."



>25^done,time={wallclock="0.00002",user="0.00001",system="0.00000",start="1384860945.770213",end="1384860945.770229"}





dUNEXPECTED GDB STDERR: gdb stack crawl at point of internal error:

dUNEXPECTED GDB STDERR: 0 gdb-i386-apple-darwin 0x000000010b315f31
internal_vproblem + 174

dUNEXPECTED GDB STDERR: 1 gdb-i386-apple-darwin 0x000000010b315e79
internal_verror + 30

dUNEXPECTED GDB STDERR: 2 gdb-i386-apple-darwin 0x000000010b315579
do_cleanups + 0

dUNEXPECTED GDB STDERR: 3 gdb-i386-apple-darwin 0x000000010b318e86
hex_string_custom + 0

dUNEXPECTED GDB STDERR: 4 gdb-i386-apple-darwin 0x000000010b35287b
macho_symfile_read + 1244

dUNEXPECTED GDB STDERR: 5 gdb-i386-apple-darwin 0x000000010b25f161
syms_from_objfile + 1270

d6 gdb-i386-apple-darwin 0x000000010b25ff3a
symbol_file_add_with_addrs_or_offsets_using_objfile + 744

dUNEXPECTED GDB STDERR: 7 gdb-i386-apple-darwin 0x000000010b2606b5
symbol_file_add_main_1 + 227

d8 gdb-i386-apple-darwin 0x000000010b260852 symbol_file_command + 134

dUNEXPECTED GDB STDERR: 9 gdb-i386-apple-darwin 0x000000010b2a94af
file_command + 29

dUNEXPECTED GDB STDERR: 10 gdb-i386-apple-darwin 0x000000010b313862
execute_command + 479

dUNEXPECTED GDB STDERR: 11 gdb-i386-apple-darwin 0x000000010b22c423
mi_execute_cli_command + 124

d12 gdb-i386-apple-darwin 0x000000010b22b6b5 captured_mi_execute_command +
490

dUNEXPECTED GDB STDERR: 13 gdb-i386-apple-darwin 0x000000010b28500a
catch_exception + 174

dUNEXPECTED GDB STDERR: 14 gdb-i386-apple-darwin 0x000000010b22b39d
mi_execute_command + 174

>~"/SourceCache/gdb/gdb-1824/src/gdb/macosx/machoread.c:739:
internal-error: assertion failure in function \"int
macho_read_indirect_symbols(bfd *, struct bfd_mach_o_dysymtab_command *,
struct bfd_mach_o_symtab_command *, struct objfile *)\": (strlen (sname) +
sizeof (\"dyld_stub_\") + 1) < 4096\n\nA problem internal to GDB has been
detected,\nfurther debugging may prove unreliable.\n"

dGDB PROCESS FINISHED, status 0, code 1

dNOTE: ENGINE ILL ******
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/qt-creator/attachments/20131119/25d3f7e7/attachment.html>


More information about the Qt-creator mailing list