Closed olahaye74 closed 2 years ago
thanks, just one question. If you want rhel 8 and above and fedora 33 and above, wouldn't it be better to use >= 33
or >= 8
? Does ex. 7.1 satisfy a > 7
?
Or is it 9/34 and above?
the %__python macro was disabled on fedora-33 (and above) and then on rhel-8 (and above). This behavior change was done on distro major version change. Thus you're right: >= 33 and >= 8 is safer.
Where is that macro actually used?
I'm confused, I had the error when building from rpmbuild -tb
Add the following lines to the rpm spec file to fix build on recent rpm distributions (fedora > 32 and RHEL > 7 at least). %python macro is not allowed anymore and will produce an error. %python2 or %__python3 must be used to clarify which python version needs to be used.
BTW, python2 is deprecated.
On Fedora-33+ and RHEL-8+, %__python triggers an error.
%if 0%{?fedora} > 32 || 0%{?rhel} > 7 %define python %python3 %endif