Visit Jeremy's Blog.
Go Back > Forums > Linux Forums > Linux - General > LQ Articles Discussion
User Name
LQ Articles Discussion This forum is for the discussion of content posted to the Articles and Editorials section.


  Search this Thread
Old 02-21-2011, 08:44 PM   #1
LQ Newbie
Registered: Oct 2009
Location: Vestal NY
Distribution: CentOS
Posts: 3

Rep: Reputation: 0
DISCUSSION: Dynamic shared library loading

A new article entry has been added:

Dynamic shared library loading

Once you create a set of functions that you like to reuse in multiple programs, you typically build them into a library. The norm in Linux now has moved away from Static libraries (*.a) and more towards Shared Libraries (*.so). Shared libraries can either be linked-in at compile time from a specific location on the system using -l and -L flags or can be loaded dynamically while the program is executing. There are advantages and disadvantages for each of those 2 cases.
Old 02-22-2011, 02:12 PM   #2
LQ Guru
Registered: Dec 2007
Distribution: Centos
Posts: 5,286

Rep: Reputation: 1194Reputation: 1194Reputation: 1194Reputation: 1194Reputation: 1194Reputation: 1194Reputation: 1194Reputation: 1194Reputation: 1194
I only got as far as the second paragraph there before seeing something I think is a wrong enough direction that it deserves correction:

Assume I am writing a server with the purpose to serve applications to users. A typical case is when the user runs a client front-end application from which he makes requests to the server to execute other applications on the server side. The requested applications has to be available to the server in the form of a loadable objects. These loadable objects or shared libraries do not have to be predefined to the server before it starts, nor does the server need to know what they do once they are loaded. All the server needs to know is where these libraries are in its file system and the name of the function the user needs to call.
I can think of almost unlimited reasons why that should be done as separate processes launched by the server, and almost no reasons why you would consider doing it via .so files loaded into the server process address space.

I know it may be hard to think of an example that is realistic while still being simple enough to work through. But this choice of example gets the whole article off to a bad start.

Edit: Now I read the whole page there. That paragraph I complained about just distracts the reader and may cause some readers to go away before reading the useful parts. It doesn't really introduce what follows.

I don't think you even need that kind of ("what is it for") introduction to what follows. The example stands better alone without the lame introduction. If you do need an introduction, it should be a more reasonable one.

Last edited by johnsfine; 02-22-2011 at 02:18 PM.


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 On
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
RedHat Dynamic loader shared library search order is backward rjbdevr Red Hat 0 03-26-2008 04:39 PM
C++ and dynamic library loading Osiris990 Programming 5 11-08-2007 11:07 AM
LINUX - linking archive (static library) with shared (dynamic) library gurkama Programming 5 03-04-2007 11:11 PM
error while loading shared library lucky6969b Programming 2 02-08-2006 12:41 AM
error loading dynamic library with Java trutnev Programming 4 06-01-2005 03:33 PM > Forums > Linux Forums > Linux - General > LQ Articles Discussion

All times are GMT -5. The time now is 01:19 AM.

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