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

Re: Dependencies on shared libs, take 2

On Thu, 07 Jun 2007, Raphael Hertzog wrote:
> Otherwise, the discussions in this thread lead to several interesting
> points (listed in the TODO in the repository) which will require some
> rewrite and optimization of the format of the symbols file. I'll update
> the wiki page and my implementation as soon as I have enough time. My goal
> is to finish this during debconf in any case.

I have updated the wiki page with the new format that I've come up:

<soname> <main dependency template>
[| <alternative dependency template>]
[ as many alternative dependency templates as needed ]
    <symbol> <first-version>[ <id of dependency template>]
    [ as many symbols as needed ]

A dependency template is a full dependency that might integrate "#MINVER#".
This place-holder is then replaced by the appropriate "(>= <min-version>)" when
the real dependency is generated. The minimal version is generated by finding
the biggest <first-version> out of all the symbols used by the application that
are affected to this dependency template. Note that #MINVER# can be empty if
the application doesn't use any symbols from a library that it's still linked

If a symbol has no explicit <id of dependency template>, then it's supposed to
be affected to the main dependency template (id=0). Otherwise the number refers
to the <n>'th alternative dependency template. 

I believe this should cover all uses cases that have been submitted to me.
Does it look ok for everybody? Of course most packages will never have any
alternative dependency and will also never put any explicit <id of
dependency template> behind the symbols. This extension is what suits best
the libGL case as explained by Steve. If you use only official symbols you get
a dependency on the virtual package, otherwise you also get a dependency on the
particular implementation that provided the other symbols. A short example might be:

libGL.so.1 libgl1-mesa-glx #MINVER# | libgl1
| libgl1-mesa-glx #MINVER#
    official_symbol@Base 6.5.1-0.6
    unofficial_symbol@Base 6.5.1-0.6 1

Raphaël Hertzog

Premier livre français sur Debian GNU/Linux :

Reply to: