[perl-Package-Stash/f13/master] Update to 0.05

Paul Howarth pghmcfc at fedoraproject.org
Fri Jul 30 10:50:18 UTC 2010


commit 3e833ce4818b5757c145b9d09b642b4d98b71c10
Author: Paul Howarth <paul at city-fan.org>
Date:   Fri Jul 30 10:34:57 2010 +0100

    Update to 0.05
    
    Update to latest upstream release, 0.05:
    - Bump Test::More requirement for done_testing
    - Update packaging stuff
    BR: perl(Test::EOL) and perl(Test::NoTabs)
    Unify spec for all active branches, adding patches for back-compatibility

 .gitignore                              |    2 +-
 Package-Stash-0.03-EU::MM-version.patch |   30 +++++++
 Package-Stash-0.05-old-Test::More.patch |  131 +++++++++++++++++++++++++++++++
 perl-Package-Stash.spec                 |   36 ++++++++-
 sources                                 |    2 +-
 5 files changed, 196 insertions(+), 5 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index 6e67260..862cf46 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1 +1 @@
-Package-Stash-0.04.tar.gz
+Package-Stash-0.05.tar.gz
diff --git a/Package-Stash-0.03-EU::MM-version.patch b/Package-Stash-0.03-EU::MM-version.patch
new file mode 100644
index 0000000..e0fb21d
--- /dev/null
+++ b/Package-Stash-0.03-EU::MM-version.patch
@@ -0,0 +1,30 @@
+--- Package-Stash-0.03/Makefile.PL	2010-05-14 17:41:34.000000000 +0100
++++ Package-Stash-0.03/Makefile.PL	2010-06-14 07:48:41.809872623 +0100
+@@ -4,7 +4,7 @@
+ 
+ 
+ 
+-use ExtUtils::MakeMaker 6.31;
++use ExtUtils::MakeMaker;
+ 
+ 
+ 
+@@ -13,7 +13,7 @@
+   'AUTHOR' => 'Jesse Luehrs <doy at tozt dot net>',
+   'BUILD_REQUIRES' => {},
+   'CONFIGURE_REQUIRES' => {
+-    'ExtUtils::MakeMaker' => '6.31'
++    'ExtUtils::MakeMaker' => '0'
+   },
+   'DISTNAME' => 'Package-Stash',
+   'EXE_FILES' => [],
+@@ -46,6 +46,9 @@
+ delete $WriteMakefileArgs{CONFIGURE_REQUIRES}
+   unless eval { ExtUtils::MakeMaker->VERSION(6.52) };
+ 
++delete $WriteMakefileArgs{LICENSE}
++  unless eval { ExtUtils::MakeMaker->VERSION(6.31) };
++
+ WriteMakefile(%WriteMakefileArgs);
+ 
+ 
diff --git a/Package-Stash-0.05-old-Test::More.patch b/Package-Stash-0.05-old-Test::More.patch
new file mode 100644
index 0000000..ca53b80
--- /dev/null
+++ b/Package-Stash-0.05-old-Test::More.patch
@@ -0,0 +1,131 @@
+diff -up Package-Stash-0.05/t/01-basic.t.orig Package-Stash-0.05/t/01-basic.t
+--- Package-Stash-0.05/t/01-basic.t.orig	2010-05-14 17:41:34.000000000 +0100
++++ Package-Stash-0.05/t/01-basic.t	2010-06-07 09:53:18.570100938 +0100
+@@ -1,7 +1,7 @@
+ use strict;
+ use warnings;
+ 
+-use Test::More;
++use Test::More tests => 93;
+ use Test::Exception;
+ 
+ use Package::Stash;
+@@ -269,5 +269,3 @@ dies_ok {
+     ok(!$stash->has_package_symbol('&foo'), "got \&foo");
+     is($stash->get_package_symbol('foo'), *Baz::foo{IO}, "got foo");
+ }
+-
+-done_testing;
+diff -up Package-Stash-0.05/t/02-extension.t.orig Package-Stash-0.05/t/02-extension.t
+--- Package-Stash-0.05/t/02-extension.t.orig	2010-05-14 17:41:34.000000000 +0100
++++ Package-Stash-0.05/t/02-extension.t	2010-06-07 09:53:18.571099744 +0100
+@@ -1,7 +1,7 @@
+ use strict;
+ use warnings;
+ 
+-use Test::More;
++use Test::More tests => 15;
+ use Test::Exception;
+ 
+ {
+@@ -66,5 +66,3 @@ lives_ok {
+ } '... created %Foo::baz successfully';
+ 
+ ok(!defined($Foo::{baz}), '... the %baz slot has still not been created');
+-
+-done_testing;
+diff -up Package-Stash-0.05/t/03-io.t.orig Package-Stash-0.05/t/03-io.t
+--- Package-Stash-0.05/t/03-io.t.orig	2010-05-14 17:41:34.000000000 +0100
++++ Package-Stash-0.05/t/03-io.t	2010-06-07 09:53:18.575099708 +0100
+@@ -1,7 +1,7 @@
+ #!/usr/bin/env perl
+ use strict;
+ use warnings;
+-use Test::More;
++use Test::More tests => 11;
+ use Test::Exception;
+ 
+ {
+@@ -46,5 +46,3 @@ use Package::Stash;
+     ok($stash->has_package_symbol('baz'), "has baz");
+     is($stash->get_package_symbol('baz'), *Foo::foo{IO}, "got the right baz");
+ }
+-
+-done_testing;
+diff -up Package-Stash-0.05/t/04-get.t.orig Package-Stash-0.05/t/04-get.t
+--- Package-Stash-0.05/t/04-get.t.orig	2010-06-13 18:13:45.000000000 +0100
++++ Package-Stash-0.05/t/04-get.t	2010-06-14 14:32:39.855811492 +0100
+@@ -1,7 +1,7 @@
+ #!/usr/bin/env perl
+ use strict;
+ use warnings;
+-use Test::More;
++use Test::More tests => 10;
+ 
+ use Package::Stash;
+ 
+@@ -62,5 +62,3 @@
+     is_deeply($stash->get_or_add_package_symbol('@foo'), [1],
+             "got the right variable");
+ }
+-
+-done_testing;
+diff -up Package-Stash-0.05/t/05-isa.t.orig Package-Stash-0.05/t/05-isa.t
+--- Package-Stash-0.05/t/05-isa.t.orig	2010-05-14 17:41:34.000000000 +0100
++++ Package-Stash-0.05/t/05-isa.t	2010-06-07 09:55:14.591128547 +0100
+@@ -1,7 +1,7 @@
+ #!/usr/bin/env perl
+ use strict;
+ use warnings;
+-use Test::More;
++use Test::More tests => 1;
+ 
+ use Package::Stash;
+ 
+@@ -16,6 +16,8 @@ use Package::Stash;
+ my $stash = Package::Stash->new('Foo');
+ my @ISA = ('Bar');
+ @{$stash->get_package_symbol('@ISA')} = @ISA;
+-isa_ok('Foo', 'Bar');
+ 
+-done_testing;
++SKIP: {
++skip "Test::More >= 0.88 needed for isa_ok() tests on classes", 1 if $Test::More::VERSION < 0.88;
++isa_ok('Foo', 'Bar');
++}
+diff -up Package-Stash-0.05/t/06-addsub.t.orig Package-Stash-0.05/t/06-addsub.t
+--- Package-Stash-0.05/t/06-addsub.t.orig	2010-06-13 18:13:45.000000000 +0100
++++ Package-Stash-0.05/t/06-addsub.t	2010-06-14 14:14:10.462975877 +0100
+@@ -1,7 +1,7 @@
+ use strict;
+ use warnings;
+ 
+-use Test::More;
++use Test::More tests => 7;
+ use Test::Exception;
+ 
+ BEGIN { $^P |= 0x210 } # PERLDBf_SUBLINE
+@@ -41,5 +41,3 @@
+ 
+ is $DB::sub{'Foo::dunk'}, sprintf "%s:%d-%d", "FileName", 100, 199,
+     '... got the right %DB::sub value for dunk with specified args';
+-
+-done_testing;
+diff -up Package-Stash-0.05/t/10-synopsis.t.orig Package-Stash-0.05/t/10-synopsis.t
+--- Package-Stash-0.05/t/10-synopsis.t.orig	2010-05-14 17:41:34.000000000 +0100
++++ Package-Stash-0.05/t/10-synopsis.t	2010-06-07 09:53:18.596164680 +0100
+@@ -1,7 +1,7 @@
+ #!/usr/bin/env perl
+ use strict;
+ use warnings;
+-use Test::More;
++use Test::More tests => 3;
+ 
+ use Package::Stash;
+ 
+@@ -14,5 +14,3 @@ $stash->add_package_symbol('%foo', {bar 
+ ok(!$stash->has_package_symbol('$foo'), "doesn't have anything in scalar slot");
+ my $namespace = $stash->namespace;
+ is_deeply(*{ $namespace->{foo} }{HASH}, {bar => 1}, "namespace works properly");
+-
+-done_testing;
diff --git a/perl-Package-Stash.spec b/perl-Package-Stash.spec
index 94efbd9..abe4876 100644
--- a/perl-Package-Stash.spec
+++ b/perl-Package-Stash.spec
@@ -1,20 +1,33 @@
+# We need to patch the test suite if we have an old version of Test::More
+%global old_test_more %(perl -MTest::More -e 'printf "%d\\n", $Test::More::VERSION < 0.88 ? 1 : 0;' 2>/dev/null || echo 0)
+
+# We don't really need ExtUtils::MakeMaker > 6.31
+%global old_eumm %(perl -MExtUtils::MakeMaker -e 'printf "%d\\n", $ExtUtils::MakeMaker::VERSION < 6.31 ? 1 : 0;' 2>/dev/null || echo 0)
+
 Name:		perl-Package-Stash
-Version:	0.04
+Version:	0.05
 Release:	1%{?dist}
 Summary:	Routines for manipulating stashes
 Group:		Development/Libraries
 License:	GPL+ or Artistic
 URL:		http://search.cpan.org/dist/Package-Stash/
 Source0:	http://search.cpan.org/CPAN/authors/id/D/DO/DOY/Package-Stash-%{version}.tar.gz
+Patch0:		Package-Stash-0.03-EU::MM-version.patch
+Patch1:		Package-Stash-0.05-old-Test::More.patch
 BuildRoot:	%{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 BuildArch:	noarch
 BuildRequires:	perl(ExtUtils::MakeMaker)
 BuildRequires:	perl(Scalar::Util)
-BuildRequires:	perl(Pod::Coverage::TrustPod)
+BuildRequires:	perl(Test::EOL)
 BuildRequires:	perl(Test::Exception)
 BuildRequires:	perl(Test::More)
+BuildRequires:	perl(Test::NoTabs)
 BuildRequires:	perl(Test::Pod)
 BuildRequires:	perl(Test::Pod::Coverage)
+# Pod::Coverage::TrustPod not yet in EPEL
+%if 0%{?fedora}
+BuildRequires:	perl(Pod::Coverage::TrustPod)
+%endif
 Requires:	perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version))
 
 %{?perl_default_filter}
@@ -27,6 +40,16 @@ a simple API.
 %prep
 %setup -q -n Package-Stash-%{version}
 
+# Don't really need ExtUtils::MakeMaker >= 6.31
+%if %{old_eumm}
+%patch0 -p1
+%endif
+
+# Compatibility with old Test::More versions
+%if %{old_test_more}
+%patch1 -p1
+%endif
+
 %build
 perl Makefile.PL INSTALLDIRS=vendor
 make %{?_smp_mflags}
@@ -51,7 +74,14 @@ rm -rf %{buildroot}
 %{_mandir}/man3/Package::Stash.3pm*
 
 %changelog
-* Mon Jul 14 2010 Paul Howarth <paul at city-fan.org> - 0.04-1
+* Wed Jun 16 2010 Paul Howarth <paul at city-fan.org> - 0.05-1
+- Update to 0.05
+  - Bump Test::More requirement for done_testing
+  - Update packaging stuff
+- BR: perl(Test::EOL) and perl(Test::NoTabs)
+- Unify spec for all active branches, adding patches for back-compatibility
+
+* Mon Jun 14 2010 Paul Howarth <paul at city-fan.org> - 0.04-1
 - Update to 0.04 (get_package_symbol now doesn't autovivify stash entries; a
   new method get_or_add_package_symbol can now be used for that behavior)
 
diff --git a/sources b/sources
index 429cfed..08edc03 100644
--- a/sources
+++ b/sources
@@ -1 +1 @@
-b96daf7f799fdb9d27871b13b3730bb5  Package-Stash-0.04.tar.gz
+d7b3857aca1f22b2da06cfcd3123cbef  Package-Stash-0.05.tar.gz


More information about the perl-devel mailing list