automake
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Creating a partial library


From: Bob Friesenhahn
Subject: Re: Creating a partial library
Date: Wed, 3 Feb 2010 09:16:22 -0600 (CST)
User-agent: Alpine 2.01 (GSO 1266 2009-07-14)

On Wed, 3 Feb 2010, Andrew W. Nosenko wrote:

Therefore, the safest way is to link your "framework" into main
process (and only into main process) and let the main process to
provide these "framework" functions to the modules loaded by him.

I find it convenient to have loadable modules depend on a shared library which provides the run-time functionality that they need. This is portable, and it works great.

I agree that depending on optional/chancy PIC functionality is a bad plan and that allowing symbol collision is also fraught with peril.

Lazy symbol resolution could allow a module to resolve the symbol in the static library part introduced by another module. When that module is later unloaded, then things go "boom" since the code being used is no longer present. There is also the small matter of wasted memory if duplicate code is loaded.

Bob
--
Bob Friesenhahn
address@hidden, http://www.simplesystems.org/users/bfriesen/
GraphicsMagick Maintainer,    http://www.GraphicsMagick.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]