[haiku-3rdparty-dev] Re: lib version specification?

  • From: Niels Sascha Reedijk <niels.reedijk@xxxxxxxxx>
  • To: haiku-3rdparty-dev@xxxxxxxxxxxxx
  • Date: Fri, 31 Jul 2020 07:08:08 +0100

Hi,

On Fri, Jul 31, 2020 at 6:57 AM Pete Goodeve <pete.goodeve@xxxxxxxxxxxx>
wrote:

Sorry, I suspect this is a noob question -- and not specific to haiku --
but I've never known how to do it, and it is very relevant to hpkgs.

In a .PackageInfo file, one can specify something like (I think):
  requires{
    lib:libreadline >= 6.0
 }

but the executable just references "libreadline.so.6", and as the
current version is 8, it doesn't find it.  How does one specify a
looser requirement when building?


The first dependency is the package dependency. During install time the
package solver will determine if you have all the prerequisite packages
installed.

The versioning on the library is done by the package itself. It is common
practise to version libraries this way for two main reasons. The first is
to be able to install multiple versions of the library at the same time.
The second is to change the file name when you make (binary) incompatible
changes, so that existing executables won't have odd runtime errors. These
two reasons are not mutually exclusive.

In this case, the package system will gladly accept a libreadline with
version 8 or higher, but the library authors have decided to make changes
in such a way that they don't automatically want existing binaries to use
the newer library.

Regards,

N>

Other related posts: