Mailinglist Archive: opensuse-packaging (140 mails)

< Previous Next >
Re: [opensuse-packaging] libraries renaming problems
  • From: Philipp Thomas <philipp.thomas@xxxxxxxxx>
  • Date: Mon, 25 Feb 2008 11:36:33 +0100
  • Message-id: <o255s3t8t3vpcl7md5278lvi408joi7hlr@xxxxxxx>
On Fri, 22 Feb 2008 21:11:42 +0100, Petr Cerny wrote:

When other package Requires: "libfoo", the package manager
(and eventually the user) gets fooled and isn't able to install the
desired package.

library packages should *never* be required explicitly as it's far
better to have rpm determine the dependency automatically (with the
exclusion of sub-packages of the library package). That will make a
package dependent on the soname (i.e. internal name) of a library and
will be resolved disregarding of the package name. Example:

- libfoo1 contains libfoo.so.1.9.7 with soname libfoo.so.1. When
packaging this with AutoReqProv on, rpmbuild will add libfoo.so.1 to
libfoo1 provides.

- Binary bar linked to libfoo will have the requirement for libfoo.so.1
encoded in it (as tools like ldd or objdump will show you) which in
turn will be discovered by rpm and added to the Requires of
the package containing this binary.

When installing this package with an installer like zypper or smart
that keeps a database of provides/requires, it will from this database
detect that libfoo1.rpm is the package needed to resolve the dependency.

When using rpm directly, you have to install libfoo1.rpm together with
bar.rpm as rpm resolves dependencies only among those rpms installed
together.

That dependency won't break if you rename either or both packages, as
the real dependency is the soname provided and required by the packages.

So I don't really understand your problem.

Philipp
---------------------------------------------------------------------
To unsubscribe, e-mail: opensuse-packaging+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: opensuse-packaging+help@xxxxxxxxxxxx

< Previous Next >
References