The source path specifies the directories where the C and C++ source files are located. If you are debugging a user-mode process on the computer where the executable file was built, and if the source files are still in their original location, the debugger can automatically locate the source files.
". gdbinit" is a file you can drop in your home directory that gdb will parse when gdb launches, either from the command line or from within Xcode. Thanks now I have the . gdbinit file in my home directory.
I can set a breakpoint in main and debug the code with the correct source code, but I don't know where GDB is taking the source code from.
The source code is not present in CWD (current working directory).
How do I find from which location GDB is taking the code?
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With