qt - Xcode equivalent of Visual Studio's "Find Source" -


i developing on qt project, , have installed qt installer onto computer. in visual studio simple debug-step qt sources: when enter function in unknown file, open file browser let me locate original qt source code.

is there equivalent function in xcode or lldb?

the debug information records location of qt source files when built. can find information doing:

  (lldb) image lookup -va main     address: hello[0x0000000100000f40] (hello.__text.__text + 0)     summary: hello`main @ hello.c:5      module: file = "/private/tmp/hello", arch = "x86_64" compileunit: id = {0x00000000}, file = "/tmp/hello.c", language = "iso c:1999"    function: id = {0x00000026}, name = "main", range = [0x0000000100000f40-0x0000000100000f6d)    functype: id = {0x00000026}, decl = hello.c:4, clang_type = "int (void)"      blocks: id = {0x00000026}, range = [0x100000f40-0x100000f6d)   lineentry: [0x0000000100000f40-0x0000000100000f56): /tmp/hello.c:5      symbol: id = {0x00000004}, range = [0x0000000100000f40-0x0000000100000f6d), name="main" 

but substitute qt function "main". @ compileunit line , see "file" entry says. suppose says

"/builddirectory/sources/somesubdirectory/somefile.cpp" 

now presumably you've downloaded qt sources, , live somewhere on local machine, in

"/users/me/qt/sources" 

so want tell lldb: "when see source file rooted @ /builddirectory/sources, in /users/me/qt/sources instead." lldb "target.source-map" setting. in example, say:

(lldb) settings set target.source-map /builddirectory/sources /users/me/qt/sources 

you can type in on command line or put in .lldbinit file more general use. lldb update source maps automatically, if running in xcode, you'll have step once after issuing command update.


Comments

Popular posts from this blog

java - How to specify maven bin in eclipse maven plugin? -

single sign on - Logging into Plone site with credentials passed through HTTP -

php - Why does AJAX not process login form? -