%define	module	Class-ErrorHandler
%define name	perl-%{module}
%define	version	0.03
%define	release	1%{_dist_release}

Name:		%{name}
Version:	%{version}
Release:	%{release}
Summary:	Base class for error handling
Summary(ja):	Perl 上でエラーを扱うための基本クラス
Group:		Development/Libraries
License:	GPL or Artistic
URL:		http://search.cpan.org/dist/%{module}/
Source:         http://search.cpan.org/CPAN/authors/id/B/BT/BTROTT/%{module}-%{version}.tar.gz

BuildArch:	noarch
BuildRoot:	%{_tmppath}/%{name}-%{version}-root
BuildRequires:  perl(ExtUtils::MakeMaker)
Requires:       perl(:MODULE_COMPAT_%(eval "`perl -V:version`"; echo $version))

Vendor:         Project Vine
Distribution:   Vine Linux

%description
Class::ErrorHandler provides an error-handling mechanism that's 
generic enough to be used as the base class for a variety of OO classes. 
Subclasses inherit its two error-handling methods, error and errstr, 
to communicate error messages back to the calling program.

#'
%prep
%setup -q -n %{module}-%{version}

%build
%{__perl} ./Build.PL installdirs=vendor
./Build 

%install
rm -rf $RPM_BUILD_ROOT
./Build install destdir=$RPM_BUILD_ROOT

find $RPM_BUILD_ROOT -type f -name .packlist -exec rm -f {} ';'
find $RPM_BUILD_ROOT -depth -type d -exec rmdir {} ';' 2>/dev/null
%{_fixperms} $RPM_BUILD_ROOT

%clean
rm -rf $RPM_BUILD_ROOT

%check
./Build test

%files
%defattr(-,root,root)
%doc Changes LICENSE README.md
%{_mandir}/man3*/*
%{perl_vendorlib}/Class/*

%changelog
* Sat Nov 22 2014 Ryoichi INAGAKI <ryo1@toki.waseda.jp> 0.03-1
- updated to 0.03
- built with perl 5.16.3

* Sat Apr 30 2011 Yoji TOYODA <bsyamato@sea.plala.or.jp> 0.01-3
- rebuild with perl-5.12.3

* Thu Mar 12 2009 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 0.01-2vl5
- changed Group to Development/Libraries
- added Japanese summary

* Fri May 02 2008 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp> 0.01-1vl5
- rebuild with perl 5.10
- new versioning policy

* Mon Mar 10 2008 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp> 0.01-0vl1
- rebuild for VineSeed

* Sun Mar 09 2008 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp> 0.01-0vl0.43
- rebuild to release for VinePlus 4.2

* Tue Mar 04 2008 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp> 0.01-0vl0.42
- built for Vine 4.2 (testing)

