#182 Packaging:Python's conditional macro expression overly broad
Closed: Fixed None Opened 11 years ago by salimma.

The [http://fedoraproject.org/wiki/Packaging:Python#Macros example macro for RHEL <= 5] has this guard expression:

{{{
%if 0%{?rhel} <= 5
...
%endif
}}}

Which would actually evaluates to true if rhel is not defined at all (e.g. on any Fedora release). This should probably be replaced with

{{{
%if 0%{?rhel} && 0%{?rhel} <= 5
...
%endif
}}}


Pretty sure that was intentional as RHEL-4 didn't define the rhel macro either, although we can probably ignore that now.

It wasn't intentional. We don't take RHEL4's lack of that macro into account anywhere else in the Guidelines (probably should make a note of that on the EPEL pages1). In recent times (last few years) we've been moving things that are RHEL-specific out of the packaging guidelines altogether and adding them into the EPEL guidelines instead. I suppose that the whole guard section and definition of python_site* is a candidate for that treatment as well.

Login to comment on this ticket.

Metadata