#1198 Add notes on new dist macros
Merged 9 months ago by tibbs. Opened 2 years ago by amitshah.
amitshah/packaging-committee master  into  master

@@ -130,6 +130,20 @@ 

  

  Without the extra 0, if `+%{rhel}+` is undefined, the `+%if+` conditional will cease to exist, and the rpm will fail to build.

  

+ === Distribution-specific values

+ 

+ Fedora 37 onwards, a few helper macros are defined to help packagers write distribution-agnostic spec files:

+ 

+ `+%{dist_vendor}+`: The vendor of the distribution.  For Fedora, this is `+Fedora+`.

+ `+%{dist_name}+`: The name of the distribution.  For Fedora, this is `+Fedora Linux+`.

+ `+%{dist_home_url}+`: The URL of the homepage of the distribution. For Fedora, this is `+https://fedoraproject.org/+`

+ `+%{dist_bug_report_url}+`: The URL for reporting bugs. For Fedora, this is `+https://bugzilla.redhat.com/+`

+ `+%{dist_debuginfod_url}+`: The URL where the debuginfod server runs (if any).  This is used

+ in elfutils.spec.  For Fedora, this is `+https://debuginfod.fedoraproject.org/+`.

+ 

+ These values are configured via the `+fedora-release+` package.  Downstream distributions of

+ Fedora are expected to provide their distribution-specific values here.

+ 

  === Things that you cannot use +%{?dist}+ for

  

  * You must not override the variables for `+%{dist}+` (or any of the related variables).

The }in Fedora Linux} should be +, right?

This repository asks for semantic line breaks in the README.
Please add a line break between the two sentences.
This is particularly important because reviews are conducted on Pagure,
which does a bad job in presenting diffs of long lines to reviewers.

rebased onto e18365633156277f0c676cc9c0552132e2c0ec74

2 years ago

Fixed both.

None of the other lines in that file are broken that way; instructions in READMEs only go so far :)

Is there a way to preview the changes being made to the documentation here? I'd have caught the first typo myself if I'd found a way..

Thank you.
Unfortunately, semantic linebreaks have not been applied everywhere.
There are instructions in README for previewing,
section Building the Whole Set of Guidelines.

See also Building a local preview in the documentation docs,
but note that this repository somewhat deviates from the standard method described there.

I find that the asciidoctor.js extension for Firefox works very well, even for rendering local files.

Do we know if these macros are coming to any released versions of Fedora and/or EPEL? Certainly it's pretty trivial to backport them but if they aren't going to in all of the released versions of Fedora then we will need to note that.

There are separate questions about EPEL, whether the macros should be backported there, and whether default values of these macros would even be appropriate for EPEL packages. I can see it being something of a thorny issue, but not one that should be discussed here.

Edit: Since this is in fedora-release and not redhat-rpm-macros, It's not really up to FPC to decide whether they get backported.

Will adding "Fedora 37 onwards also provides the following macros.." help? I doubt there's much benefit to backporting these changes to F35/F36, but that can be done quite easily as well.

I agree about EPEL vs RHEL, and such - but those can be (and are being) discussed separately.

rebased onto b118d3d2a705481bd3e34ff32501bbd666c87dc9

2 years ago

Updated to mention F37 and the debuginfod_url

rebased onto 9f2bf34

9 months ago

Pull-Request has been merged by tibbs

9 months ago

I intended to wait a bit until these were generally available but here we are. Now they're available in all supported Fedora versions. I'm not sure what the EPEL status is but that's not really a question for us.

Thank you.

The changes are available in RHEL and centos as well.

I noticed the formatting was off; created another PR to fix it. https://pagure.io/packaging-committee/pull-request/1294

Metadata