Spec tidy-up

- Use author-independent source URL
- Classify buildreqs by usage
- Convert Changes file to UTF-8
- Fix permissions verbosely
- Don't need to remove empty directories from the buildroot
- Make %files list more explicit
epel9
Paul Howarth 5 years ago
parent defa4d91b9
commit ab892588c8

@ -0,0 +1,11 @@
--- Changes
+++ Changes
@@ -654,7 +654,7 @@ Revision history for Perl module Spreads
! Changed handling of undefs in write() method. Thanks Hanc Pavel.
! Changed new() to return undef for file creation errors
- Thanks Felipe Pérez Galiana.
+ Thanks Felipe Pérez Galiana.
! Added check for header/footer length. Thanks Peter Dintelmann.

@ -0,0 +1,5 @@
from Config import *
addFilter("spelling-error %description -l en_US ParseExcel -> ")
addFilter("file-not-utf8 /usr/share/doc/perl-Spreadsheet-WriteExcel/examples/unicode.*")

@ -1,29 +1,49 @@
Name: perl-Spreadsheet-WriteExcel
Version: 2.40
Release: 16%{?dist}
Release: 17%{?dist}
Summary: Write formatted text and numbers to a cross-platform Excel binary file
License: GPL+ or Artistic
URL: https://metacpan.org/release/Spreadsheet-WriteExcel
Source0: http://cpan.org/authors/id/J/JM/JMCNAMARA/Spreadsheet-WriteExcel-%{version}.tar.gz
Source0: https://cpan.metacpan.org/modules/by-module/Spreadsheet/Spreadsheet-WriteExcel-%{version}.tar.gz
Patch0: Spreadsheet-WriteExcel-2.40-utf8.patch
BuildArch: noarch
# Build
BuildRequires: coreutils
BuildRequires: findutils
BuildRequires: make
BuildRequires: perl-generators
BuildRequires: perl-interpreter
BuildRequires: perl(ExtUtils::MakeMaker)
# Runtime
BuildRequires: perl(autouse)
BuildRequires: perl(Carp)
BuildRequires: perl(Date::Calc)
BuildRequires: perl(Date::Manip)
BuildRequires: perl(Digest::MD4)
BuildRequires: perl(Encode)
BuildRequires: perl(Exporter)
BuildRequires: perl(File::Temp)
BuildRequires: perl(FileHandle)
BuildRequires: perl(Getopt::Long)
BuildRequires: perl(integer)
BuildRequires: perl(OLE::Storage_Lite) >= 0.19
BuildRequires: perl(Parse::RecDescent)
BuildRequires: perl(Test::More)
BuildRequires: perl(Pod::Usage)
BuildRequires: perl(POSIX)
BuildRequires: perl(strict)
BuildRequires: perl(Time::Local)
Requires: perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version))
Requires: perl(Date::Calc), perl(Date::Manip), perl(Parse::RecDescent)
Requires: perl(OLE::Storage_Lite) >= 0.19, perl(Encode)
BuildRequires: perl(vars)
# Test Suite
BuildRequires: perl(Test::More)
# Dependencies
Requires: perl(:MODULE_COMPAT_%(eval "`perl -V:version`"; echo $version))
Requires: perl(Date::Calc)
Requires: perl(Date::Manip)
Requires: perl(Digest::MD4)
Requires: perl(Encode)
Requires: perl(File::Temp)
Requires: perl(OLE::Storage_Lite) >= 0.19
Requires: perl(Parse::RecDescent)
%{?perl_default_filter:
%filter_requires_in %{perl_vendorlib}/Spreadsheet/WriteExcel/Examples.pm
@ -31,7 +51,6 @@ Requires: perl(OLE::Storage_Lite) >= 0.19, perl(Encode)
}
%global __requires_exclude_from %{?__requires_exclude_from:%__requires_exclude_from|}Spreadsheet/WriteExcel/Examples\\.pm$
%description
The Spreadsheet::WriteExcel module can be used to create a cross-
platform Excel binary file. Multiple worksheets can be added to a
@ -47,21 +66,23 @@ Spreadsheet::ParseExcel or look at the main documentation for some
suggestions. This module cannot be used to write to an existing
Excel file.
%prep
%setup -q -n Spreadsheet-WriteExcel-%{version}
%{__perl} -pi -e 's/\r\n/\n/g' Changes README bin/chartex \
doc/*.html examples/{README,*.{pl,txt}}
# Fix encoding of Changes file
%patch0
# Fix line endings
perl -pi -e 's/\r\n/\n/g' examples/*.txt
%build
%{__perl} Makefile.PL INSTALLDIRS=vendor
perl Makefile.PL INSTALLDIRS=vendor
make %{?_smp_mflags}
%install
make pure_install PERL_INSTALL_ROOT=$RPM_BUILD_ROOT
find $RPM_BUILD_ROOT -type f -name .packlist -exec rm -f {} ';'
find $RPM_BUILD_ROOT -type d -depth -exec rmdir {} 2>/dev/null ';'
%{_fixperms} $RPM_BUILD_ROOT/*
make pure_install DESTDIR=%{buildroot}
find %{buildroot} -type f -name .packlist -delete
%{_fixperms} -c %{buildroot}
%check
make test
@ -70,10 +91,38 @@ make test
%doc Changes README docs/ examples/
%{_bindir}/chartex
%{perl_vendorlib}/Spreadsheet/
%{_mandir}/man1/*.1*
%{_mandir}/man3/*.3*
%{_mandir}/man1/chartex.1*
%{_mandir}/man3/Spreadsheet::WriteExcel.3*
%{_mandir}/man3/Spreadsheet::WriteExcel::BIFFwriter.3*
%{_mandir}/man3/Spreadsheet::WriteExcel::Big.3*
%{_mandir}/man3/Spreadsheet::WriteExcel::Chart.3*
%{_mandir}/man3/Spreadsheet::WriteExcel::Chart::Area.3*
%{_mandir}/man3/Spreadsheet::WriteExcel::Chart::Bar.3*
%{_mandir}/man3/Spreadsheet::WriteExcel::Chart::Column.3*
%{_mandir}/man3/Spreadsheet::WriteExcel::Chart::External.3*
%{_mandir}/man3/Spreadsheet::WriteExcel::Chart::Line.3*
%{_mandir}/man3/Spreadsheet::WriteExcel::Chart::Pie.3*
%{_mandir}/man3/Spreadsheet::WriteExcel::Chart::Scatter.3*
%{_mandir}/man3/Spreadsheet::WriteExcel::Chart::Stock.3*
%{_mandir}/man3/Spreadsheet::WriteExcel::Examples.3*
%{_mandir}/man3/Spreadsheet::WriteExcel::Format.3*
%{_mandir}/man3/Spreadsheet::WriteExcel::Formula.3*
%{_mandir}/man3/Spreadsheet::WriteExcel::OLEwriter.3*
%{_mandir}/man3/Spreadsheet::WriteExcel::Properties.3*
%{_mandir}/man3/Spreadsheet::WriteExcel::Utility.3*
%{_mandir}/man3/Spreadsheet::WriteExcel::Workbook.3*
%{_mandir}/man3/Spreadsheet::WriteExcel::Worksheet.3*
%changelog
* Tue Oct 8 2019 Paul Howarth <paul@city-fan.org> - 2.40-17
- Spec tidy-up
- Use author-independent source URL
- Classify buildreqs by usage
- Convert Changes file to UTF-8
- Fix permissions verbosely
- Don't need to remove empty directories from the buildroot
- Make %%files list more explicit
* Fri Jul 26 2019 Fedora Release Engineering <releng@fedoraproject.org> - 2.40-16
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild

Loading…
Cancel
Save