Conversation
| # `mock.conf` file in a package payload is sufficient to leverage this feature. | ||
| # However, for older distributions that lack this capability, we still define | ||
| # the %%pre scriptlet. | ||
| %if (0%{?rhel} && 0%{?rhel} < 10) || (0%{?mageia} && 0%{?mageia} < 10) || (0%{?suse_version} && 0%{?suse_version} < 1660) |
There was a problem hiding this comment.
Too bad there is no macro with RPM version because this is getting out of hand.
There was a problem hiding this comment.
Yeah. I just c&p'ed this from a place where people cared (mock), but I think we are just fine to support RHEL8+ and Fedora (if you think this is too ugly).
I think the problem is how to compare %rpmversion, without lua/bash heavy lifting...
There was a problem hiding this comment.
This is cool thing, btw.
$ rpm --eval '%[v"4.20.0" > v"4.19.0"]'
1
But this is RHEL9+ only: rpm-software-management/rpm@145b5f8
There was a problem hiding this comment.
| %if (0%{?rhel} && 0%{?rhel} < 10) || (0%{?mageia} && 0%{?mageia} < 10) || (0%{?suse_version} && 0%{?suse_version} < 1660) | |
| %if %{?rpmversion:v"%{rpmversion}" >= v"4.19"}%{!?rpmversion:0} |
If the RPM version is too old for the comparison and this feature, it does not have the macro defined.
There was a problem hiding this comment.
Oh, my condition is reversed. But you get the idea.
There was a problem hiding this comment.
And I already merged the PR. But good suggestion. Thank you.
|
The CI fails only for EPEL7 which we can IMHO disable now. But the error looks fixable |
|
I disabled EPEL 7 builds. CI is green now. |
Built on top of:
https://src.fedoraproject.org/rpms/resalloc/pull-request/3
rpm-software-management/mock#1498