Re: Mass Package Change: Turn deprecated %patchN syntax into %patch -PN

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

 



On 5/10/24 14:10, Vít Ondruch wrote:
> I'd actually prefer the `%patch 1` syntax (which is also the first on
> the list [1]). Yes, I understand that `%patch -P1` is to stay on the
> safe side, but this is Fedora change, not RHEL or EPEL change.
> 
> But if you insist on `-P1`, then please skip all packages I am
> associated with. I'd prefer to have them broken and if needed, I fix
> them later myself.

We have an even easier solution for you: You can just run the script at
[3] with -n on your own spec files to get them changed to the %patch N
variant. If you do that right now they will not break nor will they be
touched during the mass change.

As I said the %patch -PN syntax is the one with the best compatibility -
 reaching back into the dark ages. I am not advocating for people to use
it. Anyone is free and encouraged to move to something more modern -
before or after the change. We are using this variant so spec files
continue to work on older distributions and the chance of breakage is
minimized. This way packagers that don't care don't have to.

Florian

> Dne 06. 05. 24 v 13:56 Florian Festi napsal(a):
>> Hi everyone,
>>
>> RPM has deprecated the %patchN syntax in favor of %patch -PN where N is
>> the patch number for a year now. See the RPM documentation for more
>> information [1]. In current RPM versions, this syntax only emits a
>> deprecation warning, but support for this syntax has been removed
>> completely in the upcoming RPM 4.20 release. As it will be added in
>> Fedora soon [2] it is time to switch over to the new syntax now.
>>
>> There are around 1800 packages that still use the old syntax. Later this
>> week/next week, we will run this script [3] over the affected packages
>> [4][5] to update them to the modern patch syntax. For example, the
>> script will change:
>>
>> %patch0 -p1 → %patch -P0 -p1
>> %patch0005 -p2 → %patch -P0005 -p2
>>
>> If anyone has any objections or would like to exclude a package, please
>> let me know.
>>
>> As this change does not affect the resulting binary packages an
>> immediate rebuild is not needed. The change will "only" ensure the
>> packages still build with the new version of RPM.
>>
>> This is the change with the highest compatibility (back to RPM 3.x).
>> There are more modern options (like %autosetup) that packagers are
>> encouraged to use but are out of scope here.
>>
>> Florian
>>
>> [1]
>> https://rpm-software-management.github.io/rpm/manual/spec.html#patch-1
>> [2] https://fedoraproject.org/wiki/Changes/RPM-4.20
>> [3] https://fedoraproject.org/wiki/File:User-Ffesti-new_patch_syntax.sh
>> [4] https://fedoraproject.org/wiki/File:User-Ffesti-patchNN-packages.txt
>> [5]
>> https://fedoraproject.org/wiki/File:User-Ffesti-patchNN-package-owners.txt
>> -- 
>> _______________________________________________
>> devel mailing list -- devel@xxxxxxxxxxxxxxxxxxxxxxx
>> To unsubscribe send an email to devel-leave@xxxxxxxxxxxxxxxxxxxxxxx
>> Fedora Code of Conduct:
>> https://docs.fedoraproject.org/en-US/project/code-of-conduct/
>> List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
>> List Archives:
>> https://lists.fedoraproject.org/archives/list/devel@xxxxxxxxxxxxxxxxxxxxxxx
>> Do not reply to spam, report it:
>> https://pagure.io/fedora-infrastructure/new_issue
> 
> --
> _______________________________________________
> devel mailing list -- devel@xxxxxxxxxxxxxxxxxxxxxxx
> To unsubscribe send an email to devel-leave@xxxxxxxxxxxxxxxxxxxxxxx
> Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/
> List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
> List Archives: https://lists.fedoraproject.org/archives/list/devel@xxxxxxxxxxxxxxxxxxxxxxx
> Do not reply to spam, report it: https://pagure.io/fedora-infrastructure/new_issue
--
_______________________________________________
devel mailing list -- devel@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe send an email to devel-leave@xxxxxxxxxxxxxxxxxxxxxxx
Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: https://lists.fedoraproject.org/archives/list/devel@xxxxxxxxxxxxxxxxxxxxxxx
Do not reply to spam, report it: https://pagure.io/fedora-infrastructure/new_issue




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Fedora Announce]     [Fedora Users]     [Fedora Kernel]     [Fedora Testing]     [Fedora Formulas]     [Fedora PHP Devel]     [Kernel Development]     [Fedora Legacy]     [Fedora Maintainers]     [Fedora Desktop]     [PAM]     [Red Hat Development]     [Gimp]     [Yosemite News]

  Powered by Linux