LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
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
  Search this Thread
Old 04-11-2006, 04:03 PM   #1
halturata
Member
 
Registered: Aug 2005
Location: Sofia
Distribution: SuSE, ELinOS
Posts: 100

Rep: Reputation: 16
How to see of which objects files is particular shared library made of?


I mean, ldd libname.so gives information only about the dependencies between the shared libraries. How can one get the list of object files which are linked into the library?
 
Old 04-11-2006, 04:35 PM   #2
graemef
Senior Member
 
Registered: Nov 2005
Location: Hanoi
Distribution: Fedora 13, Ubuntu 10.04
Posts: 2,379

Rep: Reputation: 148Reputation: 148
If I understand you correctly then I'd say that you'll need to go to the source, or documentation for that information
 
Old 04-11-2006, 04:37 PM   #3
Mara
Moderator
 
Registered: Feb 2002
Location: Grenoble
Distribution: Debian
Posts: 9,696

Rep: Reputation: 232Reputation: 232Reputation: 232
.so doesn't keep the information, AFAIK. You can see the list of symbols using readelf, that should help in most cases.
.a files keep the sources.
 
Old 04-11-2006, 09:22 PM   #4
paulsm4
LQ Guru
 
Registered: Mar 2004
Distribution: SusE 8.2
Posts: 5,863
Blog Entries: 1

Rep: Reputation: Disabled
Hi -

Just FYI,
Quote:
nm -A mysharedlib.so
and
Quote:
nm mystaticlib.a
will both let you see the exported symbols, and the required imports.

But, as the previous posters already said, the shared .so library doesn't retain any information about either the original source files, nor the intermediate .o objects.

'Hope that helps .. PSM
 
Old 04-12-2006, 01:35 AM   #5
halturata
Member
 
Registered: Aug 2005
Location: Sofia
Distribution: SuSE, ELinOS
Posts: 100

Original Poster
Rep: Reputation: 16
Thank you guys.
 
  


Reply



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



Similar Threads
Thread Thread Starter Forum Replies Last Post
Dynamically sized objects in shared memory jtshaw Programming 2 03-16-2005 10:12 AM
any links on linking, loading shared libraries, shared objects. etc? ananthbv Programming 0 02-03-2005 07:47 AM
Creating Shared objects Anup Kumar Programming 1 09-11-2004 11:45 PM
howto compile bin with my library using all-static and shared linked standart library stpg Programming 4 06-29-2004 04:20 AM
g++ missing shared objects pinguwin Linux - Software 0 05-27-2004 08:38 AM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 07:49 PM.

Main Menu
Advertisement
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
Open Source Consulting | Domain Registration