5

When I attach to process with GDB I saw that warning:

Reading symbols from /CloneFileSystem/lib/ld-uClibc.so.0...
(No debugging symbols found in /CloneFileSystem/lib/ld-uClibc.so.0)
warning: Unable to find dynamic linker breakpoint function.
GDB will be unable to debug shared library initializers
and track explicitly loaded dynamic code.

Even I use set sysroot /CloneFileSystem with all the libraries there, that not help.

My process call to function in shared library and that function call to another function in another shared library.

For example ProcessFunc-> Lib1Func -> Lib2Func

I want to debug Lib2Func but when I run command b Lib2Func gdb can't set a breakpoint there event that library is already loaded

file myexe -> interpreter /lib/ld-uClibc.so.0

When I use info sharedlibrary in GDB I can't the value in From and To (address of loaded are empty)

2
  • Do you have the dynamic loader (ld.so or ld-linux.so or whatever) in your cloned sysroot? Run file ./myexe to see the dynamic loader specified for ./myexe. Commented Dec 6, 2021 at 11:48
  • @n.1.8e9-where's-my-sharem. When I run file on this exe I got interpreter /lib/ld-uClibc.so.0 and I have this file in lib (I update my post) Commented Dec 6, 2021 at 12:56

1 Answer 1

1

You might want to try recompiling the library with a -g option. It's saying it can't find the debug info. -g provides for debugging info if you are using gcc. This is the first thing i'd check. If the library is big this may take awhile.

Sign up to request clarification or add additional context in comments.

2 Comments

I can't recompiling the library :)
I think i understand. Then you only have only compiled binaries? I don't think you would be able to do this with gdb without having the source. You might have to use a traditional IDE debugger(if you just want to debug the code), even though gdb is way cooler. I think I had a similar problem a while back when I tried to look at c stdlib functions in gdb.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.