3 %bcond_without tests # unit tests
6 %define pnam Country-DB_File
7 Summary: IP::Country::DB_File - IPv4 and IPv6 to country translation using DB_File
8 Name: perl-IP-Country-DB_File
12 License: GPL v1+ or Artistic
13 Group: Development/Languages/Perl
14 Source0: http://www.cpan.org/modules/by-module/IP/%{pdir}-%{pnam}-%{version}.tar.gz
15 # Source0-md5: 749ea4ca65126ef38d30bb386865c49e
16 URL: https://metacpan.org/dist/IP-Country-DB_File
17 BuildRequires: perl-devel >= 1:5.8.0
18 BuildRequires: rpm-perlprov >= 4.1-13
19 BuildRequires: rpmbuild(macros) >= 1.745
21 BuildRequires: perl-Math-Int64
24 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
27 IP::Country::DB_File is a light-weight module for fast IP address to
28 country translation based on DB_File. The country code database is
29 stored in a Berkeley DB file. You have to build the database using
30 build_ipcc.pl or IP::Country::DB_File::Builder before you can lookup
33 This module tries to be API compatible with the other IP::Country
34 modules. The installation of IP::Country is not required.
36 There are many other modules for locating IP addresses. Neil Bowers
37 posted an excellent review. Some features that make this module
41 %setup -q -n %{pdir}-%{pnam}-%{version}
44 %{__perl} Makefile.PL \
48 %{?with_tests:%{__make} test}
51 rm -rf $RPM_BUILD_ROOT
53 %{__make} pure_install \
54 DESTDIR=$RPM_BUILD_ROOT
57 rm -rf $RPM_BUILD_ROOT
60 %defattr(644,root,root,755)
62 %attr(755,root,root) %{_bindir}/build_ipcc.pl
63 %{perl_vendorlib}/IP/Country/*.pm
64 %{perl_vendorlib}/IP/Country/DB_File
65 %{_mandir}/man1/build_ipcc.pl.1*
66 %{_mandir}/man3/IP::Country::DB_File*.3*