I've got a project with a shared library (loaded dynamically), and I'm attempting to debug it. I get the following error message:
No source file named /home/username/Code/path/to/project/MyFile.cpp.
After having searched other threads, I've ensured that I'm compiling with -g, and that the appropriate folders are on the source paths tab of debug configurations. The strange part is that it's giving the correct absolute path: the file it references does exist, so I don't understand why it doesn't think it's there.
Anyone know what to do about this?
I just came across the same issue, although my breakpoints were in the executable itself, not in a shared library. To solve this, I had to open the "Debug configuration", select my debug configuration and adjust the following settings:
For breakpoints in shared libraries, you might need additional information (especially about deferred breakpoints) from Debugging with eclipse cdt and gdb and Why does eclipse cdt ignore breakpoints.
Note: This refers to Eclipse Kepler (4.3) and gdb 7.4.