LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (https://www.linuxquestions.org/questions/slackware-14/)
-   -   Package Maintenance: Question about dependencys (https://www.linuxquestions.org/questions/slackware-14/package-maintenance-question-about-dependencys-4175603071/)

ArthurFontolan 04-02-2017 09:31 PM

Package Maintenance: Question about dependencys
 
Hi,

Well, just one simple question:

If I upgrade a library, like libbluray, is it necessary recompiling all the programs which depend of it?

I have the MPV installed on my system, which depends of FFMPEG which was compiled with libbluray support. The libbluray was updated so should I recompile FFMPEG and MPV or is not necessary?

Thank You

frankbell 04-02-2017 09:45 PM

Based on my own experience with Slackware, I can respond with a resounding "It depends."

The best thing to do is to test the applications one at a time (I'd start with ffmpeg) and see whether they experience any issues.

bassmadrigal 04-03-2017 07:19 AM

frankbell speaks the truth. It usually is dependent on whether the developers bump the ABI version or not. If the ABI version stays the same, then the upgraded library shouldn't affect your current programs (shouldn't... but things still happen). Sometimes, even if the ABI is bumped, then it may still work with previous versions, depending on how much the developer has changed and whether the library's file(s) the program links to have changed. Sometimes you can fix things with a symlink (although, this is not recommended, because then you have random symlinks on your filesystem that are not tracked by Slackware's package manager.

This is one (of the many) reasons I like using slackrepo to manage my SBo library of packages. If a dependency is updated, it will recompile its parent applications to try and minimize issues that could occur by updating. There might be other tools that handle this as well, although, I haven't looked into them.

montagdude 04-03-2017 07:49 AM

Quote:

Originally Posted by bassmadrigal (Post 5691943)
This is one (of the many) reasons I like using slackrepo to manage my SBo library of packages. If a dependency is updated, it will recompile its parent applications to try and minimize issues that could occur by updating. There might be other tools that handle this as well, although, I haven't looked into them.

Shameless plug incoming, but sboui does it too. Not automatically, though.

Actually, there's something that does it for the base system too. It's called Patrick Volkerding. ;)

bormant 04-03-2017 11:48 PM

Always yes if the program uses the static library (in this case some library code is copied into the program executable file at compile time).

dugan 04-04-2017 12:33 AM

Usually not.

But FFMPEG is an exception where you usually do need to recompile the programs that depend on it.

55020 04-04-2017 05:33 AM

If pkgA requires pkgB requires pkgC, and pkgC is updated, and all of them are installed through SBo packages, then
  • C, C++ => pkgB probably needs rebuild, pkgA probably does not need rebuild (see footnotes)
  • python, perl, java => Usually no rebuild
  • haskell, ruby => both pkgA and pkgB need rebuild

Footnote 1. pkgB needs a rebuild if the "soname" of a shared library in pkgC has changed. It's a lot of work to find out whether this has happened, or if pkgC is statically linked, or only a build-time dep, or only invoked through the command line, so it's safer to just do the rebuild.

Footnote 2. SBo rules for REQUIRES in the .info files say that the list of deps can be simplified, and if both pkgA and pkgB require pkgC, then pkgC should not be in the REQUIRES of pkgA. Unfortunately this makes it impossible to know whether pkgA needs a rebuild when pkgC is updated.

If you don't want to work through all those decisions every time there's an update, the safe choice is always to rebuild both pkgA and pkgB.

montagdude 04-04-2017 07:53 AM

Quote:

Originally Posted by 55020 (Post 5692351)
If you don't want to work through all those decisions every time there's an update, the safe choice is always to rebuild both pkgA and pkgB.

Probably good advice. Another option (what most people probably do) would be to just deal with any issues as you encounter them, but if that ends up being a long time down the road, you may be confused about why pkgA or pkgB "suddenly" stopped working.

bassmadrigal 04-04-2017 08:29 AM

Quote:

Originally Posted by montagdude (Post 5692424)
Probably good advice. Another option (what most people probably do) would be to just deal with any issues as you encounter them, but if that ends up being a long time down the road, you may be confused about why pkgA or pkgB "suddenly" stopped working.

That's why on my old 14.1 install, that I primarily used sbopkg to install software, I'd never upgrade any packages from SBo (well, almost never... if I figured it was a safe update, I might do it). I was too worried about what that upgrade might knock out. That has mostly been solved by using slackrepo (created by 55020), so I'm free to run the latest versions and update whenever there's new versions put out.


All times are GMT -5. The time now is 07:58 PM.