rpm: Simplify expression of supported platforms

Stanzas like "0%{?fedora} && 0%{?fedora} >= %{min_fedora}" contain
redundant definitions, as "0%{?fedora} >= %{min_fedora}" implies that
"%fedora" is defined and has a value. Thus, we can simplify this.

Signed-off-by: Neal Gompa <ngompa13@gmail.com>
Reviewed-by: Jiri Denemark <jdenemar@redhat.com>
This commit is contained in:
Neal Gompa 2021-01-07 09:58:08 -05:00 committed by Jiri Denemark
parent a42adc2714
commit 0a28ea6f59

View File

@ -6,7 +6,7 @@
%define min_rhel 7
%define min_fedora 31
%if (0%{?fedora} && 0%{?fedora} >= %{min_fedora}) || (0%{?rhel} && 0%{?rhel} >= %{min_rhel})
%if 0%{?fedora} >= %{min_fedora} || 0%{?rhel} >= %{min_rhel}
%define supported_platform 1
%else
%define supported_platform 0