New major version of forge macros in redhat-rpm-config

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




Hi,

As some of you have noticed a major rework of the forge macros has finally landed in rawhide:
https://koji.fedoraproject.org/koji/buildinfo?buildID=1155046

(helpers to package projects hosted on Gitlab, Github, Googlecode, Bitbucket, etc)


It adds the ability to process multiple source archives in a single spec. That was the main missing feature, pointed out by reviewers during the initial integration last year.

If you do not need the feature there should be no intentional change in the way the macros behave.


If you do need it it's now possible via two switches:
1. -z <number>: process the numberth block of definitions in the spec file 2. -a: process every blocks of source definitions in one go, without separate -z calls

A contrived spec example that pulls every kind of source the macro supports right now is given in:
https://src.fedoraproject.org/rpms/redhat-rpm-config/pull-request/35


The last version of the macros was documented through
https://fedoraproject.org/wiki/Forge-hosted_projects_packaging_automation

That proved not too successful. The wiki page was a lot of effort to write and maintain, packagers do not read it, FPC never figured how to integrate it in guidelines. And then there is the new docs project.

Therefore, I now intend to drop this wiki page. And just ship some example spec templates in a redhat-rpm-config subpackage or somewhere else¹. That should be easier to maintain, to audit, to keep up to date, and to use by Fedora packagers.


Calling the same block of macro code several times with different settings, and without side effects, in the same spec, required a huge amount of cleanups and refactoring. Including, bugfixes in rpm itself.

Thus, while there is no intentional behaviour change for packagers that only use a single source archive in their spec, the cleanups may change or remove some undocumented and unintended ways to use the macros that were possible in the previous version.

For those reasons, while a backport to stable or even epel-rpm-macros is planed, it won't occur immediately.


If you are the maintainer of complex packaging macros in Fedora, the whole content of
https://src.fedoraproject.org/rpms/redhat-rpm-config/c/c70110c677904a188d66ffd01a9ab024469ca62d

may be of interest. Implementing this feature required lots of macro infra work which is completely generic and not forge-specific.

If you are just a rpm macro user, you can ignore this plumbing.


Many thanks to the redhat-rpm-config maintainers that had the thankless task to help me do things that were never done or possible before. Evaluating new code, without a past reference to build upon, is always scary.

Best regards,


¹ That mostly depends on what FPC decides in https://pagure.io/packaging-committee/issue/813

--
Nicolas Mailhot
_______________________________________________
packaging mailing list -- packaging@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe send an email to packaging-leave@xxxxxxxxxxxxxxxxxxxxxxx
Fedora Code of Conduct: https://getfedora.org/code-of-conduct.html
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: https://lists.fedoraproject.org/archives/list/packaging@xxxxxxxxxxxxxxxxxxxxxxx




[Index of Archives]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite Forum]     [KDE Users]

  Powered by Linux