Srv19
Srv19

Reputation: 3608

How to determine if libpthread and libthread_db match?

Is there a way to determine whether given libpthread and libthread_db found on the system match?

Only way i know is to try and launch gdb on the program built with libpthread library. Is there any other?

Upvotes: 4

Views: 428

Answers (1)

Ben C
Ben C

Reputation: 658

Joe Damato has a blog post explaining how to load libthread_db in C to inspect another process running libpthread. If this succeeds then you know that these libraries match. Unfortunately to do this you need to write a significant chunk of a debugger including reading from the process's memory and searching its symbol tables, so this isn't a simple answer.

Upvotes: 1

Related Questions