开发者

Specifying RPM dependency as "one of the following"

开发者 https://www.devze.com 2023-02-11 18:59 出处:网络
I am developing an RPM spec file for an in-house package. The package depends on libuuid, which is available as the libuuid package on Fedora, but there is no libuuid package for CentOS 5 in the stand

I am developing an RPM spec file for an in-house package. The package depends on libuuid, which is available as the libuuid package on Fedora, but there is no libuuid package for CentOS 5 in the standard RPM repositories. We can satisfy the dependency on CentOS with the e2fsprogs-devel development RPM (e2fsprogs-devel installs libuuid and the 开发者_开发问答associated headers). I would like to specify that our RPM depends on libuuid, such that the libuuid package is installed on Fedora during installation of our RPM, but e2fsprogs-devel is installed during installation on CentOS. Is there a way to specify a dependency as "one of libuuid or e2fsprogs-devel, in that order" in an RPM spec file?


You may directly specify files as a requirement but this is ugly. Also don't use %dist for distinguishing.

You should just rely on the build process. If one specific file is located in different packages depending on the distro then you should just (re-) build the package on every distro you wish to support (AutoReq/AutoReqProv must not be disabled).


No. Use the Dist Tag to distinguish between Fedora and one of its derivatives.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号