Isn't mono
the interpreter for your language and test.exe
the binary? lldb only knows about mono
-- any breakpoints you try to set would be in the mono
interpreter. e.g. if you were debugging an issue with mono
itself.
This is a unique enough environment that you'll need to do a little analysis to understand what lldb sees. What do you get for
(lldb) image list test.exe
? Of course if you do
(lldb) im li mono
You'll see mono listed -- because that's a binary that lldb knows about. (you can use plain image list
aka im li
to see all the binaries that lldb knows)
You can ask lldb to list all of the line table entries based on a source filename with a command line
(lldb) target modules dump line-table test.cs
if lldb has any debug information for a test.cs
, you'll see a line table. Without a line table, file and line breakpoints (b test.cs:16
) won't work.
For what it's worth, I don't think trying to use lldb (or gdb) to debug your C# program will work. You'll probably need to use some facility of the mono runtime itself to set breakpoints and examine program state.