Reputation: 1
I want to create an rpm listing two dependencies. And RPM should be able to install if either of the dependency is satisfied. What should be mentioned in its spec file.. Any suggestions/help will be appreciated.
Upvotes: 0
Views: 66
Reputation: 1
Simply put 'or' between the dependencies.
For ex. Requires: gcc Requires: g++ For any package I need either gcc or g++ , So instead of checking for both I can check or either of it.
Better way is to .. Requires: g++ or gcc
if we need further options then just put after or like...
Requires: python or g++ or gcc or etc, python
Upvotes: 0
Reputation: 69224
Make up a name for the feature that both of the alternate RPMs provide. For example, MyCoolFeature. You can then put this line in the spec files for both of the RPMs:
Provides: MyCoolFeature
And in the spec file for the RPM that requires one of these alternate RPMs, you can put:
Requires: MyCoolFeature
Upvotes: 2