LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices

Reply
 
LinkBack Search this Thread
Old 09-09-2009, 11:30 AM   #1
famsinyi
LQ Newbie
 
Registered: Nov 2007
Posts: 25

Rep: Reputation: 0
dynamically list all symbols from a shared library


My application needs the list of all functions exported by a shared library at run time. How can this be done in Linux programming using c++?

Last edited by famsinyi; 09-09-2009 at 07:46 PM.
 
Old 09-09-2009, 04:33 PM   #2
theNbomr
LQ 5k Club
 
Registered: Aug 2005
Distribution: OpenSuse, Fedora, Redhat, Debian
Posts: 5,390
Blog Entries: 2

Rep: Reputation: 900Reputation: 900Reputation: 900Reputation: 900Reputation: 900Reputation: 900Reputation: 900Reputation: 900
You haven't said anything about your programming language, but most languages provide a method of spawning a child process, and capturing it's stdout & stderr streams. You could use this method to spawn ldd, and capture and parse it's output.
--- rod.
 
Old 09-09-2009, 06:21 PM   #3
theNbomr
LQ 5k Club
 
Registered: Aug 2005
Distribution: OpenSuse, Fedora, Redhat, Debian
Posts: 5,390
Blog Entries: 2

Rep: Reputation: 900Reputation: 900Reputation: 900Reputation: 900Reputation: 900Reputation: 900Reputation: 900Reputation: 900
This thread on another board seems to have the same conclusion, with more detail.
--- rod.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
list library function of a shared library .so powah Linux - General 7 10-25-2011 04:47 AM
Debugger selectively not using symbols in library with symbols Millenniumman Programming 5 03-25-2007 09:44 AM
Debugger selectively not using symbols in library with symbols Millenniumman Programming 1 03-03-2007 07:46 PM
Hiding global symbols in a shared/static library jineshkj Programming 16 08-30-2006 12:45 AM


All times are GMT -5. The time now is 10:40 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration