Why does rpm built not able to find the library from the system?
Issue
- Create a package
foo
v1 containing a shared library (/usr/local/lib/libfoo.so
) which does not set thesoname
- Create a package bar using this shared library
# rpm -qRp bar.rpm | grep foo
libfoo.so
- Create a new version of package
foo
v2 where the shared library now sets thesoname
and is installed as a symbolic link from/usr/local/lib/libfoo.so
to/usr/local/lib/libfoo.so.1
- The
bar
program built against the original verson oflibfoo
can find it regardless of whether the old or new version is installed. - However, installation of
bar
whenfoo
v2 is installed fails dependency checking.
error: Failed dependencies:
libfoo.so is needed by bar
- Likewise an upgrade from
foo
v1 to foo v2 will fail for the same reason. - One needs to recompile (relink)
bar
againstlibfoo.so.1
. - Shall
rpm
should not understand thatlibfoo.so
is inclusive oflibfoo.so.1
when checking dependencies. - That is, the behavior of
rpm
should match the behavior of the OS.
Environment
- Red Hat Enterprise Linux 7
rpm-build
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.