From: Ruben Kerkhof Date: Sat, 4 Jun 2016 12:18:57 +0000 (+0200) Subject: collectd.spec: only require python26 on RHEL < 6 X-Git-Tag: collectd-5.6.0~249 X-Git-Url: https://git.verplant.org/?a=commitdiff_plain;h=602d8828fe4ead5148a261af0f9e81b6b9b720ea;p=collectd.git collectd.spec: only require python26 on RHEL < 6 Otherwise the else clause in the condition matches on Fedora too. This makes the spec build on Fedora. --- diff --git a/contrib/redhat/collectd.spec b/contrib/redhat/collectd.spec index ce37c52a..c8c1c258 100644 --- a/contrib/redhat/collectd.spec +++ b/contrib/redhat/collectd.spec @@ -603,10 +603,10 @@ Summary: Perl plugin for collectd Group: System Environment/Daemons Requires: %{name}%{?_isa} = %{version}-%{release} Requires: perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version)) - %if 0%{?rhel} >= 6 -BuildRequires: perl-ExtUtils-Embed - %else + %if 0%{?rhel} && 0%{?rhel} < 6 BuildRequires: perl + %else +BuildRequires: perl-ExtUtils-Embed %endif %description perl The Perl plugin embeds a Perl interpreter into collectd and exposes the @@ -651,10 +651,10 @@ database. Summary: Python plugin for collectd Group: System Environment/Daemons Requires: %{name}%{?_isa} = %{version}-%{release} - %if 0%{?rhel} >= 6 -BuildRequires: python-devel - %else + %if 0%{?rhel} && 0%{?rhel} < 6 BuildRequires: python26-devel + %else +BuildRequires: python-devel %endif %description python The Python plugin embeds a Python interpreter into collectd and exposes the @@ -1369,10 +1369,10 @@ Collectd utilities %endif %if %{with_python} - %if 0%{?rhel} >= 6 -%define _with_python --enable-python - %else + %if 0%{?rhel} && 0%{?rhel} < 6 %define _with_python --enable-python --with-python=%{_bindir}/python2.6 + %else +%define _with_python --enable-python %endif %else %define _with_python --disable-python