[lug] library naming conventions, sym links

Chan Kar Heng karheng at softhome.net
Sun Jul 17 05:35:17 MDT 2005


hi all,

the only implication i can suggest is that an rpm packager has the 
responsibility to recreate all sym links with every update & can't be 
lazy with the way rpm prefers it (the latter way).

eg:

Existing:
libSomeLib.so.0.0.0
libSomeLib.so.0.0 -> libSomeLib.so.0.0.0
libSomeLib.so.0 -> libSomeLib.0.0
libSomeLib.so -> libSomeLib.0

Introduction of a patch/minor upgrade:
libSomeLib.so.0.0.1

Update required:
rm libSomeLib.so.0.0
ln -s libSomeLib.so.0.0.1 libSomeLib.so.0.0

All libSomeLib.so.0.0, libSomeLib.so.0 & libSomeLib.so still refer to 
the new/latest libSomeLib.

if on the otherhand:

Existing:
libSomeLib.so.0.0.0
libSomeLib.so.0.0 -> libSomeLib.so.0.0.0
libSomeLib.so.0 -> libSomeLib.so.0.0.0
libSomeLib.so -> libSomeLib.so.0.0.0

Introduction of a patch/minor upgrade:
libSomeLib.so.0.0.1

Update required:
rm libSomeLib.so.0.0 libSomeLib.so.0 libSomeLib.so
ln -s libSomeLib.so.0.0.1 libSomeLib.so.0.0
# these are also required, else libSomeLib.so.0 & libSomeLib.so breaks.
ln -s libSomeLib.so.0.0.1 libSomeLib.so.0
ln -s libSomeLib.so.0.0.1 libSomeLib.so

i'd assume rpm assumes packagers aren't lazy & always recreates all 
symlinks..?

rgds,

kh


Lee Woodworth wrote:
> Hugh Brown wrote:
> 
>>On Sat, 2005-07-16 at 18:38 -0600, D. Stimits wrote:
>>
>>
>>>I've always thought that libraries (dynamic) would be named in the 
>>>format of:
>>>libSomeLib.so.0.0.0
>>>...then a sym link created for
>>>libSomeLib.so.0.0 -> libSomeLib.so.0.0.0
>>>libSomeLib.so.0 -> libSomeLib.0.0
>>>libSomeLib.so -> libSomeLib.0
>>>
>>>However, it seems that rpm is telling me this is wrong. Rpm seems to 
>>>want to do this, where libSomeLib.so.0.0.0 is the hard link:
>>>libSomeLib.so -> libSomeLib.so.0.0.0
>>>libSomeLib.so.0 -> libSomeLib.so.0.0.0
>>>libSomeLib.so.0.0 -> libSomeLib.so.0.0.0
> 
> There are fewer symlinks traversed with this setup. You have
> libxxx.so -> libxxx.0.0.0 vs. libxxx.so -> libxxx.s.0 ... -> libxxx.so.0.0.0
> 
>>>Is this a correct standard, with the top scenario being wrong? It seems 
>>>like rpm is breaking things (or at least looking for a way to cause 
>>>version breakage) by using the latter version of sym link.
>>>
>>>D. Stimits, stimits AT comcast DOT net
>>>_______________________________________________
>>
>>
>>
>>The only difference I see in your question is the linking order
>>
>>e.g.
>>
>>ln -s libSomeLib.so.0.0.0 libSomeLib.so.0.0
>>ln -s libSomeLib.so.0.0.0 libSomeLib.so.0
>>ln -s libSomeLib.so.0.0.0 libSomeLib.so
>>
>>
>>
>>ln -s libSomeLib.so.0.0.0 libSomeLib.so
>>ln -s libSomeLib.so.0.0.0 libSomeLib.so.0
>>ln -s libSomeLib.so.0.0.0 libSomeLib.so.0.0
>>
>>I'm assuming I've misunderstood your question, because I don't think
>>either way would cause problems.
>>
>>Hugh
>>
>>_______________________________________________
>>Web Page:  http://lug.boulder.co.us
>>Mailing List: http://lists.lug.boulder.co.us/mailman/listinfo/lug
>>Join us on IRC: lug.boulder.co.us port=6667 channel=#colug
> 
> 
> _______________________________________________
> Web Page:  http://lug.boulder.co.us
> Mailing List: http://lists.lug.boulder.co.us/mailman/listinfo/lug
> Join us on IRC: lug.boulder.co.us port=6667 channel=#colug
> 



More information about the LUG mailing list