+#
+# Conditional build:
+%bcond_without tests # do not perform "make test"
+#
%include /usr/lib/rpm/macros.perl
%define pdir Date
%define pnam Manip
Summary: Date::Manip - date manipulation routines
Summary(pl.UTF-8): Date::Manip - procedury do operowania na datach
Name: perl-Date-Manip
-Version: 5.44
-Release: 2
+Version: 6.41
+Release: 1
# same as perl
License: GPL v1+ or Artistic
Group: Development/Languages/Perl
-Source0: http://www.cpan.org/modules/by-module/%{pdir}/%{pdir}%{pnam}-%{version}.tar.gz
-# Source0-md5: ebb1e17639fc4260b72690c1de2f5fdc
+Source0: http://www.cpan.org/modules/by-module/Date/%{pdir}-%{pnam}-%{version}.tar.gz
+# Source0-md5: 5fd8ba69642db5fc87a99eab6376c0ac
+URL: http://search.cpan.org/dist/Date-Manip/
BuildRequires: perl-devel >= 1:5.8.0
BuildRequires: rpm-perlprov >= 4.1-13
+%if %{with tests}
+BuildRequires: perl-Test-Inter
+BuildRequires: perl-YAML-Syck
+%endif
Obsoletes: perl-DateManip
BuildArch: noarch
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
%description
Perl module Date::Manip contains a set of routines designed to make
-any common date/time manipulation easy to do. Operations such as
+any common date/time manipulation easy to do. Operations such as
comparing two times, calculating a time a given amount of time from
another, or parsing international times are all easily done.
czasową - wszystkie łatwo wykonać.
%prep
-%setup -q -n %{pdir}%{pnam}-%{version}
+%setup -q -n %{pdir}-%{pnam}-%{version}
%build
%{__perl} Makefile.PL \
INSTALLDIRS=vendor
%{__make}
+%{?with_tests:%{__make} test}
+
%install
rm -rf $RPM_BUILD_ROOT
%{__make} install \
DESTDIR=$RPM_BUILD_ROOT
+%{__rm} $RPM_BUILD_ROOT%{perl_vendorlib}/Date/{Manip,Manip/*,Manip/Lang/*}.pod
+
%clean
rm -rf $RPM_BUILD_ROOT
%files
%defattr(644,root,root,755)
-%doc README TODO *.cnf
+%doc HISTORY LICENSE README.first
+%attr(755,root,root) %{_bindir}/dm_date
+%attr(755,root,root) %{_bindir}/dm_zdump
%{perl_vendorlib}/Date/Manip.pm
-%{_mandir}/man3/*
+%dir %{perl_vendorlib}/Date/Manip
+%{perl_vendorlib}/Date/Manip/*.pm
+%dir %{perl_vendorlib}/Date/Manip/Lang
+%{perl_vendorlib}/Date/Manip/Lang/*.pm
+%dir %{perl_vendorlib}/Date/Manip/Offset
+%{perl_vendorlib}/Date/Manip/Offset/*.pm
+%dir %{perl_vendorlib}/Date/Manip/TZ
+%{perl_vendorlib}/Date/Manip/TZ/*.pm
+%{_mandir}/man1/dm_date.1p.gz
+%{_mandir}/man1/dm_zdump.1p.gz
+%{_mandir}/man3/Date::Manip*.3pm*