[SOLVED] Rpmbuild issues - how to use a particular library
Linux - SoftwareThis forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Excuse what is a bit of a long story, but not sure how to explain the problem clearly otherwise.
I regularly build rpm packages of hugin and darktable, both have a dependency on exiv2. The current Fedora 21 repo version is exiv2-0.24.
I needed exiv2-0.25 for darktable for new camera support.
I can't use rpmbuild to build and install exiv2-0.25 as it will break binary compatibility with quite a few installed packages; it provides libexiv2.so.14, whereas exiv2-0.24 provides libexiv2.so.13.
To get around this I did a local build of exiv2-0.25 (not using rpmbuild or package manager), and installed in /usr/local, so I now have libexiv2.so.14 in /usr/local/lib, and libexiv2.so.13 in /usr/lib64 which is known by the rpm database.
I then did a local build of darktable, which automatically linked to libexiv2.so.14, and I installed in /usr/local.
Now this is where the trouble starts! I now want to continue to use rpmbuild to build hugin, and this goes OK until I try to install the package and I find the builds now depend on libexiv2.so.14, which the rpm database doesn't believe is installed. The rpmbuild of hugin finds the libexiv2 in /usr/local/lib and not the one in /usr/lib64.
A couple of additional relevant details. The hugin build uses cmake, and I have control over how cmake is called in my .spec file, but I don't have any control over the hugin CmakeLists.txt file.
How can I get the hugin build to use the libexiv2 in /usr/lib64?...or more specifically, if it is a proper question, is there a way to specify where cmake looks for libs on the command line call to cmake?
Yes you can if you use a virtual server (or maybe using one of the build services out there)?
Do you mean something like Fedora's 'mock'?
How is that going to help? Do you mean build exiv2-0.25, and All the other packages I have installed that depend on exiv2, in mock, then install the lot?
Whoops...I think I picked up the wrong end of the stick!
I guess you mean build hugin in mock, or similar. Yes I could, but I think I found a simpler way.
Just 'make uninstall' in my exiv2-0.25 src dir, which gets rid of libexiv2.so.14, build and install hugin, then 'make install' in exiv2 dir again.
A bit of a nasty way around my predicament, but certainly simpler than building a virtual machine.
Thanks for your help, and sorry for not paying attention!
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.