Bug 1524192

Summary: [RFE] Define %{dist} as %{?distprefix}.fc#
Product: [Fedora] Fedora Reporter: Nicolas Mailhot <nicolas.mailhot>
Component: fedora-releaseAssignee: Dennis Gilmore <dennis>
Status: CLOSED RAWHIDE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: rawhideCC: carl, dennis, jdisnard, jkeating, j, kellin, kevin, mboddu, pbrobinson, sgallagh, zbyszek
Target Milestone: ---   
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: 2018-02-02 00:13:03 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:

Description Nicolas Mailhot 2017-12-10 16:33:43 UTC
fedora-release should define %dist as

%dist %{?distprefix}.fc#

in /usr/lib/rpm/macros.d/macros.dist

This way other macros could compute a dist prefix without clobbering dist itself

An example of complex dist prefix is the one Fedora Packaging guidelines require for snapshots in:
https://fedoraproject.org/wiki/Packaging:Versioning#More_complex_versioning

An snapshot automation macro is proposed in
https://fedoraproject.org/wiki/Forge-hosted_projects_packaging_automation

Right now it has to redefine %{dist} in a non-reversible way

Comment 1 Jason Tibbitts 2018-01-12 00:57:11 UTC
For the record, I agree with this.  I've run into the problem this solves a couple of times in my macro experiments.

Is there any reason we can't just do this?  It's a trivial one-line tweak to the spec, though there's also a spec in the upstream repository and so I'm not entirely sure where this change would happen.

Comment 2 Kevin Fenzi 2018-01-19 19:24:28 UTC
I'm fine with this too, can someone submit a PR to fedora-release upstream doing this? It not I can try and do so sometime...

Comment 4 Kevin Fenzi 2018-02-02 00:13:03 UTC
Done and just built in rawhide. Should show up in tomorrow's compose.