%define LiteCountry_stamp 20070802 Summary: C library finding what country an IP/hostname originates from Name: GeoIP Version: 1.4.3 Release: 1.n0i.11%{?dist} Group: System Environment/Libraries License: LGPLv2+ URL: http://www.maxmind.com/app/c Source0: http://www.maxmind.com/download/geoip/api/c/%{name}-%{version}.tar.gz BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: zlib-devel %description GeoIP is a C library that enables the user to find the country that any IP address or hostname originates from. It uses a file based database that is accurate as of March 2003. This database simply contains IP blocks as keys, and countries as values. This database should be more complete and accurate than using reverse DNS lookups. Commercial databases and automatic update services are available from http://www.maxmind.com/ This module can be used to automatically select the geographically closest mirror, to analyze your web server logs to determine the countries of your visitors, for credit card fraud detection, and for software export controls. %package devel Summary: Development files for %{name} Group: Development/Libraries Requires: %{name} = %{version}-%{release} %description devel The %{name}-devel package contains libraries and header files for developing applications that use %{name}. %package Lite-Country Summary: GeoLite Country database file Group: System Environment/Libraries Version: %{LiteCountry_stamp} Requires: %{name} %description Lite-Country This package contain the country database for GeoIP. %prep %setup -q %build %configure --disable-static --disable-dependency-tracking %{__make} %{?_smp_mflags} %{?!_without_test:%{__make} check} %install %{__rm} -rf $RPM_BUILD_ROOT %{makeinstall} # fix CONF_DIR in geoipupdate man page %{__sed} 's,CONF_DIR,%{_sysconfdir},' man/geoipupdate.1 > $RPM_BUILD_ROOT/%{_mandir}/man1/geoipupdate.1 # convert man pages to UTF8 for manpage in $RPM_BUILD_ROOT%{_mandir}/man1/* ; do iconv -f "iso-8859-1" -t utf-8 < "${manpage}" > "${manpage}_" %{__mv} -f "${manpage}_" "${manpage}" done %clean %{__rm} -rf $RPM_BUILD_ROOT %post -p /sbin/ldconfig %postun -p /sbin/ldconfig %files %defattr(-,root,root) %doc AUTHORS COPYING ChangeLog README TODO conf/GeoIP.conf.default %{_bindir}/* %{_libdir}/*.so.* %config(noreplace) %{_sysconfdir}/* %exclude %{_sysconfdir}/*.default %dir %{_datadir}/%{name} %{_mandir}/*/* %files devel %defattr(-,root,root) %{_includedir}/* %{_libdir}/*.so %exclude %{_libdir}/*.la %files Lite-Country %defattr(-,root,root) %{_datadir}/%{name}/* %changelog * Tue Sep 11 2007 Marius FERARU - 1.4.3-1.n0i.11 - version 1.4.3 - license update * Mon May 14 2007 Marius FERARU - 1.4.2-1.n0i.10 - version 1.4.2 * Mon Feb 05 2007 Marius FERARU - 1.4.1-1.n0i.9 - version 1.4.1 * Mon Aug 21 2006 Marius FERARU - 1.4.0-1.n0i.8 - version 1.4.0 * Tue Jul 18 2006 Marius FERARU - 1.3.17-1.n0i.7 - version 1.3.17 * Fri Mar 31 2006 Marius FERARU - 1.3.14-4.n0i.6 - use %%{_datadir}/GeoIP folder for database files - renamed "GeoIP-data" to "GeoIP-Lite-Country" - convert man pages to UTF8 * Thu Feb 02 2006 Marius FERARU 1.3.14-1.n0i.5 - version 1.3.14 * Mon Aug 01 2005 Marius FERARU 1.3.13-1.n0i.4 - version 1.3.13 * Sat Jul 23 2005 Marius FERARU 1.3.8-3.n0i.3 - minor spec tweaks - rebuild * Sat Dec 04 2004 Marius FERARU 0:1.3.8-2.n0i.2 - version 1.3.8 * Thu Jan 08 2004 Marius FERARU 0:1.3.1-0.n0i.1 - Fedora-ized spec file - moved .so files into devel package - excluded duplicate configuration file - excluded *.la filed from devel package - stripped binaries - moved dbdir into /var/lib/%%{name} - moved database file into a separate package - fixed CONF_DIR in geoipupdate man page * Mon Sep 8 2003 Dr. Peter Bieringer - Fix for RHL 9, created a new devel package definition. * Thu Feb 27 2003 Ryan Weaver - Initial RPM Build