From 6f88362fe592d3b869ed898ef822d20f47f11b1d Mon Sep 17 00:00:00 2001 From: Paul Howarth Date: Thu, 14 Apr 2011 10:52:14 +0100 Subject: [PATCH] Tweak provides filter to work with rpm >= 4.9 too --- perl-UNIVERSAL-moniker.spec | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/perl-UNIVERSAL-moniker.spec b/perl-UNIVERSAL-moniker.spec index a40a690..3627b39 100644 --- a/perl-UNIVERSAL-moniker.spec +++ b/perl-UNIVERSAL-moniker.spec @@ -1,6 +1,6 @@ Name: perl-UNIVERSAL-moniker Version: 0.08 -Release: 13%{?dist} +Release: 14%{?dist} Summary: Real world naming for classes Group: Development/Libraries License: GPL+ or Artistic @@ -11,6 +11,9 @@ BuildArch: noarch BuildRequires: perl(Test::More), perl(Lingua::EN::Inflect) Requires: perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version)) +# Filter bogus provide for perl(UNIVERSAL) (rpm 4.9 onwards) +%global __provides_exclude ^perl\\(UNIVERSAL\\) + %description UNIVERSAL::moniker enables classes to make a good guess at what they would be called in the real world. @@ -18,13 +21,9 @@ guess at what they would be called in the real world. %prep %setup -q -n UNIVERSAL-moniker-%{version} -cat << \EOF > %{name}-prov -#!/bin/sh -%{__perl_provides} $* |\ - sed -e '/^perl(UNIVERSAL)$/d' -EOF -%define __perl_provides %{_builddir}/UNIVERSAL-moniker-%{version}/%{name}-prov -chmod +x %{__perl_provides} +# Filter bogus provide for perl(UNIVERSAL) (prior to rpm 4.9) +%global provfilt /bin/sh -c "%{__perl_provides} | sed -e '/^perl(UNIVERSAL)$/d'" +%define __perl_provides %{provfilt} %build %{__perl} Makefile.PL INSTALLDIRS=vendor @@ -51,6 +50,9 @@ rm -rf $RPM_BUILD_ROOT %changelog +* Thu Apr 14 2011 Paul Howarth - 0.08-14 +- Tweak provides filter to work with rpm >= 4.9 too + * Wed Feb 09 2011 Fedora Release Engineering - 0.08-13 - Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild