[CS-FSLUG] The Advantages of Dependency Hell

Brian Derr bderr at myrealbox.com
Tue Feb 22 15:05:54 CST 2005


On Mon, Feb 21, 2005 at 08:33:25PM -0500, Don Parris wrote:
[...]
> So when I port the program over to GNU/Linux (or write a new one), I
> assume I am making my program dependent on (linking to) various
> libraries that *should* be available in the system already, thus
> reducing duplicitous coding and duplicate copies of libraries (which
> might take up unnecessary space).
> 
> I really want to be sure my understanding (at least at a basic level)
> is accurate.  Are the reasons for linking programs the same reasons I
> mention?  I mean, for someone new to all of this, it could be a bit
> daunting.  I never really paid it much attention, to be honest.  Why
> is there no dependency hell in Windows?  Is it because the devs
> include all the necessary libraries in their program?  Should I assume
> this is an inefficient coding practice?

The reason that you can run into dependency problems with the *nix
platform is the shear volume of libraries.  For a lot of applications it
is easy to stick to the standard libraries (GNU C library for instance).
However, if you decide to add GUI functionality or something not covered
by glibc you'll have to either find a library that has your
functionality or write it yourself.

Finding a library is usually not a problem as kind hearted open source
folks like posting their useful libraries.  The problem arises when you
have to decided whether you want to add a static version of said library
to your project (assuming the libraries license allows for this) or make
a note in the INSTALL file that XYZ library is needed.  Obviously
writing your own library is going to negate this completely.

If you are going to be packaging the project into a .rpm or .deb that
has dependency support you can tell it that XYZ lib is needed and it
will inform the user it needs to also install XYZ.

Hopefully this answers your question in more words than you needed.  :-)

Brian
-- 
The just man walketh in his integrity:
his children are blessed after him.  -- Proverbs 20:7




More information about the Christiansource mailing list