%define _use_internal_dependency_generator 0

Summary: A Perl module containing a wide variety of date manipulation routines.
Name: perl-DateManip
Version: 5.44
Release: 0vl1
License: distributable
Group: Development/Libraries
Source0: DateManip-%{version}.tar.gz
Url: http://search.cpan.org/~sbeck/DateManip/
BuildRoot: %{_tmppath}/%{name}-%{version}-root/
BuildRequires: perl >= 5.8.2
Requires: perl >= 5.8.2
BuildArch: noarch

%description
This is a set of routines designed to make 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.

# Provide perl-specific find-{provides,requires}.
%define __find_provides /usr/lib/rpm/find-provides.perl
%define __find_requires /usr/lib/rpm/find-requires.perl

%prep
%setup -q -n DateManip-%{version} 

%build
CFLAGS="$RPM_OPT_FLAGS" perl Makefile.PL INSTALLDIRS=vendor
make

%check
make test

%clean 
rm -rf $RPM_BUILD_ROOT

%install
rm -rf $RPM_BUILD_ROOT
mkdir -p $RPM_BUILD_ROOT%{_prefix}
make DESTDIR=$RPM_BUILD_ROOT install

[ -x /usr/lib/rpm/brp-compress ] && /usr/lib/rpm/brp-compress

find $RPM_BUILD_ROOT \( -name perllocal.pod -o -name .packlist \) -exec rm -v {} \;

find $RPM_BUILD_ROOT/usr -type f -print | 
	sed "s@^$RPM_BUILD_ROOT@@g" | 
	grep -v perllocal.pod | 
	grep -v "\.packlist" > DateManip-%{version}-filelist
if [ "$(cat DateManip-%{version}-filelist)X" = "X" ] ; then
    echo "ERROR: EMPTY FILE LIST"
    exit -1
fi

%files -f DateManip-%{version}-filelist
%defattr(-,root,root)

%changelog
* Sun Sep 10 2006 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 5.44-0vl1
- new upstream release
- installed files to vendor_perl
- changed URL

* Sun Jan  2 2005 IWAI, Masaharu <iwai@alib.jp> 5.42a-0vl3
- build on perl-5.8.6-0vl1

* Sat Dec 13 2003 Satoshi MACHINO <machino@vinelinux.org> 5.42a-0vl2
- rebuilt on perl-5.8.2

* Thu Nov 06 2003 Satoshi MACHINO <machino@vinelinux.org> 5.42a-0vl1
- new upstream version 
- built on perl-5.8.1

* Sun Apr 29 2003 Satoshi MACHINO <machino@vinelinux.org> 5.40-30vl2
- build on perl-5.8.0

* Sun Mar 02 2003 Satoshi MACHINO <machino@vinelinux.org> 5.40-30vl1
- build for VineLinux

* Tue Aug  6 2002 Chip Turner <cturner@redhat.com>
- automated release bump and build

* Wed Jan 09 2002 Tim Powers <timp@redhat.com>
- automated rebuild

* Fri Dec 7 2001 root <root@redhat.com>
- Spec file was autogenerated. 
