Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.

Bug 1538566

Summary: RFE: Backport weak dependency support to EL7 RPM
Product: Red Hat Enterprise Linux 7 Reporter: Neal Gompa <ngompa13>
Component: rpmAssignee: Packaging Maintenance Team <packaging-team-maint>
Status: CLOSED WONTFIX QA Contact: BaseOS QE Security Team <qe-baseos-security>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 7.7CC: carlwgeorge, ffesti, germano.massullo, kwalker, mdomonko, mkolaja
Target Milestone: pre-dev-freezeKeywords: FutureFeature, Reopened
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2019-01-04 10:20:20 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1658333    
Attachments:
Description Flags
Patch from SUSE to add weak deps support to YUM none

Description Neal Gompa 2018-01-25 10:24:28 UTC
Description of problem:
It's currently not possible to specify weak dependencies for packages, which makes it difficult to deal with optional dependencies.

Currently, the recommended approach is either to make them mandatory (i.e. Requires) or to not specify them at all. Both approaches are terrible for obvious reasons.

Could we have the weak dependency tags backported from RPM 4.12 to RHEL 7 RPM such that packages can be built with them and RPM can process them? That would also offer parity with SLE 12 RPM 4.11, which offers this functionality, and make it easier for packages from Fedora to be built for RHEL in EPEL.

Version-Release number of selected component (if applicable):
4.11.3-25.el7

Comment 3 Florian Festi 2018-09-21 12:11:42 UTC
The issue here is that we do not support weak deps in yum properly and adding support in rpmbuild might give the impression that weak deps are actually fully supported through out RHEL 7. I am closing this here.

From a technical POV adding the support should be pretty easy (We are talking about weak dependencies only - not boolean dependencies).

Comment 4 Neal Gompa 2018-12-11 21:10:24 UTC
Created attachment 1513521 [details]
Patch from SUSE to add weak deps support to YUM

(In reply to Florian Festi from comment #3)
> The issue here is that we do not support weak deps in yum properly

This is supported in yum git master currently (it works in Fedora and Mageia yum-deprecated).

If you want a more specific patch, SUSE has a patch that can be adapted, which I've attached.

And we now have DNF in RHEL 7, which supports it too.

> adding support in rpmbuild might give the impression that weak deps are
> actually fully supported through out RHEL 7. I am closing this here.
> 

With the attached patch, it could be...

> From a technical POV adding the support should be pretty easy (We are
> talking about weak dependencies only - not boolean dependencies).

Yeah, we don't really want to go down the ugly road of boolean dependencies...

Comment 5 Michal Domonkos 2018-12-13 10:24:12 UTC
(In reply to Neal Gompa from comment #4)
> This is supported in yum git master currently (it works in Fedora and Mageia
> yum-deprecated).

While it's true that the upstream version of yum does have support for weak deps, we're not planning on backporting it to RHEL-7 at this point.  It's just too many changes and we don't want to risk regressions.