From 3a9f72f4c2b4cf2cf282c880d8c1e640fabf242f Mon Sep 17 00:00:00 2001
From: Paul Howarth <p...@city-fan.org>
Date: Fri, 19 Feb 2016 13:09:10 +0000
Subject: Make SYNOPSIS compilable perl (#1309966)

---
 Test-Mojibake-1.1-synopsis.patch | 13 +++++++++++++
 perl-Test-Mojibake.spec          | 21 +++++++++++++++++----
 2 files changed, 30 insertions(+), 4 deletions(-)
 create mode 100644 Test-Mojibake-1.1-synopsis.patch

diff --git a/Test-Mojibake-1.1-synopsis.patch b/Test-Mojibake-1.1-synopsis.patch
new file mode 100644
index 0000000..79b1d20
--- /dev/null
+++ b/Test-Mojibake-1.1-synopsis.patch
@@ -0,0 +1,13 @@
+--- lib/Test/Mojibake.pm
++++ lib/Test/Mojibake.pm
+@@ -318,8 +318,8 @@ version 1.1
+     # Test::Mojibake lets you check for inconsistencies in 
source/documentation encoding, and report its results in standard Test::Simple 
fashion.
+ 
+     use Test::Mojibake;
+-    file_encoding_ok($file, 'Valid encoding');
+-    done_testing($num_tests);
++    file_encoding_ok('test.pl', 'Valid encoding');
++    done_testing();
+ 
+ =head1 DESCRIPTION
+ 
diff --git a/perl-Test-Mojibake.spec b/perl-Test-Mojibake.spec
index 0f8a57b..79ec2f8 100644
--- a/perl-Test-Mojibake.spec
+++ b/perl-Test-Mojibake.spec
@@ -7,15 +7,16 @@
 
 Name:          perl-Test-Mojibake
 Version:       1.1
-Release:       2%{?dist}
+Release:       3%{?dist}
 Summary:       Check your source for encoding misbehavior
 Group:         Development/Libraries
 License:       GPL+ or Artistic
 URL:           http://search.cpan.org/dist/Test-Mojibake/
 Source0:       
http://search.cpan.org/CPAN/authors/id/S/SY/SYP/Test-Mojibake-%{version}.tar.gz
-Patch0:                Test-Mojibake-1.1-no-Test::Version.patch
+Patch0:                Test-Mojibake-1.1-synopsis.patch
 Patch1:                Test-Mojibake-1.1-old-Test::More.patch
 Patch2:                Test-Mojibake-1.0-old-Test::Pod.patch
+Patch3:                Test-Mojibake-1.1-no-Test::Version.patch
 BuildRoot:     %{_tmppath}/%{name}-%{version}-%{release}-root-%(id -nu)
 BuildArch:     noarch
 # ===================================================================
@@ -119,6 +120,9 @@ Enter the Test::Mojibake ;)
 %prep
 %setup -q -n Test-Mojibake-%{version}
 
+# Make SYNOPSIS compilable perl (#1309966)
+%patch0
+ 
 # We need to patch the test suite if we have an old version of Test::More
 %if %{old_test_more}
 %patch1
@@ -131,7 +135,7 @@ Enter the Test::Mojibake ;)
 
 # Test::Version not always available
 %if !0%{?fedora} && 0%{?rhel} < 7
-%patch0
+%patch3
 %endif
 
 %build
@@ -154,13 +158,22 @@ make test %{!?perl_bootstrap:AUTHOR_TESTING=1 
RELEASE_TESTING=1} \
 rm -rf %{buildroot}
 
 %files
-%doc Changes LICENSE README
+%if 0%{?_licensedir:1}
+%license LICENSE
+%else
+%doc LICENSE
+%endif
+%doc Changes README
 %{_bindir}/scan_mojibake
 %{perl_vendorlib}/Test/
 %{_mandir}/man1/scan_mojibake.1*
 %{_mandir}/man3/Test::Mojibake.3*
 
 %changelog
+* Fri Feb 19 2016 Paul Howarth <p...@city-fan.org> - 1.1-3
+- Make SYNOPSIS compilable perl (#1309966)
+- Use %%license where possible
+
 * Thu Feb 04 2016 Fedora Release Engineering <rel...@fedoraproject.org> - 1.1-2
 - Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
 
-- 
cgit v0.12


        
http://pkgs.fedoraproject.org/cgit/perl-Test-Mojibake.git/commit/?h=master&id=3a9f72f4c2b4cf2cf282c880d8c1e640fabf242f
--
Fedora Extras Perl SIG
http://www.fedoraproject.org/wiki/Extras/SIGs/Perl
perl-devel mailing list
perl-devel@lists.fedoraproject.org
http://lists.fedoraproject.org/admin/lists/perl-devel@lists.fedoraproject.org

Reply via email to