[CentOS-devel] perl-devel package

Wed Jul 30 23:40:31 UTC 2008
Kenneth Porter <shiva at sewingwitch.com>

--On Thursday, July 31, 2008 12:29 AM +0300 Manuel Wolfshant 
<wolfy at nobugconsulting.ro> wrote:

> Wrong approach. Apply Johnny's advice. Or be polite and modify the spec
> to distinguish between building on fedora >=7  or on Centos (RHEL).
> Something along the following line should do:
>
> %if 0%{?fedora} > 6
>   BuildRequires perl-devel
> %else
>   BuildRequires perl
> %endif

That almost works. The spec parser didn't like the leading white space on 
BuildRequires, and it's missing the colon. The following seems to work:

%if 0%{?fedora} > 6
BuildRequires: perl-devel >= 2:5.8.0
%else
BuildRequires: perl >= 2:5.8.0
%endif