I am trying to build a rpm package using cmake. This package builds a library and packages it well all is hunky-dory
In the next iteration, I add "soname" using the following commands
set_property(TARGET ${MY_TARGET} PROPERTY VERSION "${SO_VERSION_STRING}")
set_property(TARGET ${MY_TARGET} PROPERTY SOVERSION "${MAJOR_STRING}")
I install (before packaging in to rpm we need to install) it using the following:
install ( DIRECTORY <PATH_WHERE_LIBS_ARE> DESTINATION <PATH_WHERE_IT_NEEDS_TO_RESIDE> FILES_MATCHING PATTERN "libABC.so*" )
When the rpm compiles on Ubuntu it does not shows any dependency
rpm -qpR my-package-x.yy.zz.pppp.x86_64.rpm
/bin/sh
/bin/sh
rpmlib(CompressedFileNames) <= 3.0.4-1
rpmlib(FileDigests) <= 4.6.0-1
rpmlib(PayloadFilesHavePrefix) <= 4.0-1
When it compiles on CentOS it addeds a dependency :
rpm -qpR my-package-x.yy.zz.pppp.x86_64.rpm
/bin/sh
/bin/sh
/bin/sh
/bin/sh
/bin/sh
/bin/sh
libABC.so.1()(64bit)
rpmlib(CompressedFileNames) <= 3.0.4-1
rpmlib(FileDigests) <= 4.6.0-1
rpmlib(PayloadFilesHavePrefix) <= 4.0-1
rpmlib(PayloadIsXz) <= 5.2-1
The question is why is libABC.so.1()(64bit) , is being added a dependency by CentOS?
Also, why there is this problem happening only with the "sonames". There is no problem when soname is not added / packaged.
I tried to do lot of search / investigation but could not come up with the exact cause. This problem :
"Missing" lib for rpm install when it is present in rpm file
Describes the same problem as mine without using cmake (using plain spec files for rpm) but no solution. I tried to checked if there is some issue with architecture (x32 , x64 ) as discussed there but, it seems all fine.