Bug 1017051

Summary: Add DNF support
Product: [Fedora] Fedora Reporter: Vít Ondruch <vondruch>
Component: mockAssignee: Miroslav Suchý <msuchy>
Status: CLOSED WORKSFORME QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: rawhideCC: akozumpl, danielkza2, mebrown, msuchy, williams
Target Milestone: ---Keywords: FutureFeature
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Enhancement
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-05-16 13:52: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:

Description Vít Ondruch 2013-10-09 08:17:32 UTC
DNF is in Fedora since F18. Since it should become replacement for YUM in F21/F22 (not sure about the timeframe), it might be the right time to add DNF support into mock.

Thanks for considering.

Comment 1 Miroslav Suchý 2014-05-16 13:52:20 UTC
There is nothing special about yum in mock. You can remove /usr/bin/yum and make it symlink to /usr/bin/dnf and it should work (and this what will likely happen in F20).

I tried to replace:
        self.yum_path = '/usr/bin/yum'
by 
        self.yum_path = '/usr/bin/dnf'
in
  /usr/lib/python2.7/site-packages/mockbuild/backend.py
which is only occurence of yum in mock and I was able to build packages successfuly.

Generaly spoken, mock is ready. If you find some corner case, please report it separately.

Comment 2 Daniel Miranda 2014-11-04 20:42:10 UTC
Right now the mock package still depends on yum-utils, and the code seems to only know about yum's cache/repo directories. It would be nice to have that updated and an optional dependency on dnf introduced.

Comment 3 Miroslav Suchý 2014-11-05 07:36:37 UTC
Yum is still primary package manager. The change will not happen till F22 and/or till we will have rich dependencies in rpm.