[csw-maintainers] Shared library placement proposal

Philip Brown phil at bolthole.com
Thu Feb 3 19:38:31 CET 2011


On Thu, Feb 3, 2011 at 10:05 AM, Peter FELECAN <pfelecan at opencsw.org> wrote:
> Philip Brown <phil at bolthole.com> writes:
>
>>
>> "Public shared libraries, the ones that other software projects can
>> link to, should be put directly under /opt/csw/lib.
>> If a project is compiled using a custom prefix and the installer puts
>> shared libraries under /opt/csw/foo/lib, [change start here]
>> a symlink  /opt/csw/libXX -> /opt/csw/foo/lib/libXXX, should be
>> created. Additionally, this symlink should be created IF and ONLY if,
>> the SONAME and filename for the library are unique. If on the other
>> hand, there is potential for multiple versions of the library to be
>> installed at one time, under different prefixes (/opt/csw/foo3,4,5),
>> and the SONAME is not unique, then no symlink in /opt/csw/lib should
>> be created.
>> "
>>
>> Rational for this has already been given in the above-referenced email thread.
>
> The rationale was re-read and I still don't get it. Can you develop in a
> more intelligible way please?

I'm not sure how I could make it any more clear. It seems pretty clear to me.
So instead, let me put it to you another way:

"it's less work".

Just adding in a symlink from /opt/csw/lib to whereever, is less work
than having to move a file from /opt/csw/prefix to /opt/csw/lib, and
then also having to make a symlink from /opt/csw/prefix to the new
location. One action, vs two.

We need to have the library visible in both locations, to avoid
confusion to both users, and potential auto-detect scripts. Ones that
tend to have single flags like --use-libfoo=/prefix, rather than 3
separate flags for --usr-libfoo-lib, --use-libfoo-include,
--use-libfoo-iforgettheotherthing

And to reply in advance to Maciej, I dont think that "well we can just
let GAR do the work, so 'more work' doesnt count", applies.  We could
inappropriately justify all kinds of nonsense with that attitude.

Simpler, is better.


More information about the maintainers mailing list