parent
6343825cee
commit
5930fa4fe2
@ -0,0 +1 @@
|
|||||||
|
/Locale-US-1.2.tar.gz
|
@ -0,0 +1,20 @@
|
|||||||
|
diff -up Locale-US-1.2/US.pm.orig Locale-US-1.2/US.pm
|
||||||
|
--- Locale-US-1.2/US.pm.orig 2007-07-17 01:06:51.000000000 +0200
|
||||||
|
+++ Locale-US-1.2/US.pm 2011-01-27 06:19:26.000000000 +0100
|
||||||
|
@@ -36,6 +36,7 @@ sub new {
|
||||||
|
|
||||||
|
my $class = shift;
|
||||||
|
my $self = {} ;
|
||||||
|
+ my $start_pos = tell( DATA );
|
||||||
|
|
||||||
|
while ( <DATA>) {
|
||||||
|
chomp;
|
||||||
|
@@ -46,6 +47,8 @@ sub new {
|
||||||
|
$self->{state2code}{$state} = $code;
|
||||||
|
}
|
||||||
|
|
||||||
|
+ seek( DATA, $start_pos, 0 );
|
||||||
|
+
|
||||||
|
# warn Dumper $self;
|
||||||
|
bless $self, $class;
|
||||||
|
}
|
@ -0,0 +1,53 @@
|
|||||||
|
Name: perl-Locale-US
|
||||||
|
Version: 1.2
|
||||||
|
Release: 1%{?dist}
|
||||||
|
Summary: Two letter codes for state identification in the United States and vice versa
|
||||||
|
License: GPL+ or Artistic
|
||||||
|
Group: Development/Libraries
|
||||||
|
URL: http://search.cpan.org/dist/Locale-US/
|
||||||
|
Source0: http://www.cpan.org/authors/id/T/TB/TBONE/Locale-US-%{version}.tar.gz
|
||||||
|
# https://rt.cpan.org/Public/Bug/Display.html?id=56989
|
||||||
|
Patch0: locale_us.patch
|
||||||
|
BuildArch: noarch
|
||||||
|
BuildRequires: perl(ExtUtils::MakeMaker)
|
||||||
|
Requires: perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version))
|
||||||
|
|
||||||
|
%{?perl_default_filter}
|
||||||
|
|
||||||
|
%description
|
||||||
|
Map from US two-letter codes to states and vice versa.
|
||||||
|
|
||||||
|
%prep
|
||||||
|
%setup -q -n Locale-US-%{version}
|
||||||
|
%patch0 -p1
|
||||||
|
|
||||||
|
# doesn't actually use Data::Dumper
|
||||||
|
sed -i -e '/use Data::Dumper/d' US.pm
|
||||||
|
|
||||||
|
# we don't need this
|
||||||
|
rm -f kruft2codes.pl
|
||||||
|
|
||||||
|
%build
|
||||||
|
%{__perl} Makefile.PL INSTALLDIRS=vendor
|
||||||
|
make %{?_smp_mflags}
|
||||||
|
|
||||||
|
%install
|
||||||
|
make pure_install DESTDIR=%{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
|
||||||
|
|
||||||
|
%files
|
||||||
|
%defattr(-,root,root,-)
|
||||||
|
%doc Changes README
|
||||||
|
%{perl_vendorlib}/*
|
||||||
|
%{_mandir}/man3/*
|
||||||
|
|
||||||
|
%changelog
|
||||||
|
* Thu Jan 27 2011 Iain Arnell <iarnell@gmail.com> 1.2-1
|
||||||
|
- Specfile autogenerated by cpanspec 1.78.
|
Loading…
Reference in new issue