Blob Blame History Raw
Name:		perl-Math-Calc-Units
Version:	1.07
Release:	9%{?dist}
Summary:	Human-readable unit-aware calculator
License:	GPLv2 or Artistic
Group:		Development/Libraries
URL:		http://search.cpan.org/dist/Math-Calc-Units
Source0:	http://search.cpan.org/CPAN/authors/id/S/SF/SFINK/Math-Calc-Units-%{version}.tar.gz
BuildArch:	noarch
BuildRoot:	%{_tmppath}/%{name}-%{version}-%{release}-root-%(id -nu)
BuildRequires:	perl(base)
BuildRequires:	perl(Carp)
BuildRequires:	perl(constant)
BuildRequires:	perl(Exporter)
BuildRequires:	perl(ExtUtils::MakeMaker)
BuildRequires:	perl(File::Basename)
BuildRequires:	perl(Getopt::Long)
BuildRequires:	perl(Test::More)
BuildRequires:	perl(Test::Pod)
BuildRequires:	perl(Time::Local)
Requires:	perl(:MODULE_COMPAT_%(eval "`perl -V:version`"; echo $version))

# Remove unwanted provide if we have rpm 4.9 or later
%global __provides_exclude ^perl\\(Parse::Yapp::Driver\\)

%description
Math::Calc::Units is a simple calculator that keeps track of units. It
currently handles combinations of byte sizes and duration only, although
adding any other multiplicative types is easy. Any unknown type is treated
as a unique user type (with some effort to map English plurals to their
singular forms).

%prep
%setup -q -n Math-Calc-Units-%{version}

# Remove unwanted provide if we don't have rpm 4.9 or later
%global provfilt /bin/sh -c "%{__perl_provides} | sed -e '/perl(Parse::Yapp::Driver)/d'"
%define __perl_provides %{provfilt}

%build
perl Makefile.PL INSTALLDIRS=vendor
make %{?_smp_mflags}

%install
rm -rf %{buildroot}
make pure_install DESTDIR=%{buildroot}
find %{buildroot} -type f -name .packlist -exec rm -f {} \;
%{_fixperms} %{buildroot}

# Remove file we don't need packaging
rm %{buildroot}%{perl_vendorlib}/Math/Calc/Units/Grammar.y

%check
make test

%clean

%files
%doc Artistic.html Changes COPYING LICENSE README
%{_bindir}/ucalc
%{perl_vendorlib}/Math/
%{_mandir}/man3/Math::Calc::Units.3pm*

%changelog
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.07-9
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild

* Fri Jul 20 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.07-8
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild

* Mon Jun 11 2012 Petr Pisar <ppisar@redhat.com> - 1.07-7
- Perl 5.16 rebuild

* Sun Apr  1 2012 Paul Howarth <paul@city-fan.org> - 1.07-6
- License is "GPLv2 or Artistic", not "GPLv2+ or Artistic"
- BR: perl(Test::Pod) for additional test coverage
- BR: Perl core modules that might be dual-lived
- Make %%files list more explicit
- Drop %%defattr, redundant since rpm 4.4
- Fix provides filter to work with rpm ≥ 4.9
- Don't need to remove empty directories from buildroot
- Use DESTDIR rather than PERL_INSTALL_ROOT
- Don't use macros for commands
- Reinstate buildroot definition and cleaning for EPEL-5 compatibility
- Use tabs

* Fri Jan 13 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.07-5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild

* Fri Jun 17 2011 Marcela Mašláňová <mmaslano@redhat.com> - 1.07-4
- Perl mass rebuild

* Tue Feb 08 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.07-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild

* Mon Dec 20 2010 Marcela Maslanova <mmaslano@redhat.com> - 1.07-2
- Rebuild to fix problems with vendorarch/lib (#661697)

* Thu Jun 24 2010 Ruben Kerkhof <ruben@rubenkerkhof.com> - 1.07-1
- Upstream released new version

* Mon May 03 2010 Marcela Maslanova <mmaslano@redhat.com> - 1.06-4
- Mass rebuild with perl-5.12.0

* Mon Dec  7 2009 Stepan Kasal <skasal@redhat.com> - 1.06-3
- Rebuild against perl 5.10.1

* Wed Jul 29 2009 Ruben Kerkhof <ruben@rubenkerkhof.com> - 1.06-2
- Review fixes (#513874)

* Sun Jul 26 2009 Ruben Kerkhof <ruben@rubenkerkhof.com> - 1.06-1
- Initial import