Blob Blame History Raw

Name:       perl-MooseX-ConfigFromFile 
Version:    0.02 
Release:    3%{?dist}
# see lib/MooseX/ConfigFromFile.pm
License:    GPL+ or Artistic 
Group:      Development/Libraries
Summary:    An abstract Moose role for setting attributes from a configfile 
Source:     http://search.cpan.org/CPAN/authors/id/B/BL/BLBLACK/MooseX-ConfigFromFile-%{version}.tar.gz 
Url:        http://search.cpan.org/dist/MooseX-ConfigFromFile
BuildRoot:  %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) 
Requires:   perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version))
BuildArch:  noarch

BuildRequires: perl(ExtUtils::MakeMaker) 
BuildRequires: perl(Moose) >= 0.35
BuildRequires: perl(MooseX::Types::Path::Class) >= 0.04
BuildRequires: perl(Test::More) >= 0.42


%description
This is an abstract role which provides an alternate constructor for
creating objects using parameters passed in from a configuration file. The
actual implementation of reading the configuration file is left to concrete
subroles.

It declares an attribute 'configfile' and a class method 'new_with_config',
and requires that concrete roles derived from it implement the class method
'get_config_from_file'.

Attributes specified directly as arguments to 'new_with_config' supercede
those in the configfile.

%prep
%setup -q -n MooseX-ConfigFromFile-%{version}

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

%install
rm -rf %{buildroot}

make pure_install PERL_INSTALL_ROOT=%{buildroot}
find %{buildroot} -type f -name .packlist -exec rm -f {} ';'
find %{buildroot} -depth -type d -exec rmdir {} 2>/dev/null ';'

%{_fixperms} %{buildroot}/*

%check
make test

%clean
rm -rf %{buildroot} 

%files
%defattr(-,root,root,-)
%doc ChangeLog README t/
%{perl_vendorlib}/*
%{_mandir}/man3/*.3*

%changelog
* Sun Jul 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.02-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild

* Thu Feb 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.02-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild

* Wed Nov 05 2008 Chris Weyl <cweyl@alumni.drew.edu> 0.02-1
- brush up for submission

* Mon Oct 27 2008 Chris Weyl <cweyl@alumni.drew.edu> 0.02-0.1
- initial RPM packaging
- generated with cpan2dist (CPANPLUS::Dist::RPM version 0.0.5)