On Sun, 11 Mar 2001, W. Kent Starr wrote:

> > Includes are a nightmare
> > that should not be inflicted on future generations. :-)
>
> Well, the concept is a good one -- bundle frequently and commonly used
> constructs into a single file and write to that. And, almost everybody has
> them...whether they are called "include"s, "require"s or whatever.  The
> problem comes when my code is writtern to a later version of myinclude.h
> which is different from the version of myinclude.h you have on your system
> (and you didn't know that one of of the several thousand include files from
> various libraries, distros, etc. has been functionally changed) and you try
> to compile Dave's "superguy.cpp" and, well, it doesn't compile (or worse,
> compiles and feeds back subtle, erroneous results. And it's not just a
> programmers' headache, either. Many Windows end-users find program A stops
> working because the just-installed program B overwrites MSWHATEVER.DLL! But
> the only feedback _they_ get is a GPF or blue screen of death when they try
> to run A again. Not a pretty sight!

Apple of all companies is actually taking a crack at the problem[1]. One
of the few really impressive parts of Mac OS X is the Framework concept
they're using. Basically a framework can store multiple versions of the
same libraries/headers/resources and allow applications to link to the
correct versions (and find localized libraries, etc.). There's some
potential for bloat, but it could potentially kill most of the library
hell we otherwise end up in. I just hope that Darwin (the open source core
of OS X) leads to this same functionality being adopted in Linux etc[2].

There's some coverage at:
http://arstechnica.com/reviews/2q00/macos-x-dp4/macos-x-dp4-2.html and
http://developer.apple.com/techpubs/macosx/CoreFoundation/BundleServices/CFBundleServices/index.html
documents "Bundle Services" (a framework is a type of bundle, as are
applications and plug-ins).

All in all a very cool technology and one of the first plausible attempts
I've seen at beating back the library compatibility issue.

Jonathan Conway


[1] Okay, they _are_ dedicated to user friendliness, I just never thought
    this included developers.
[2] I've seen it suggested that the Open Packages initiative for the BSDs
    - and potentially other (OS)^2 - may do this.