]>
Commit | Line | Data |
---|---|---|
8a44bed0 | 1 | Summary: Library to find what country an IP address or hostnames originate from |
5d437b3a | 2 | Summary(pl.UTF-8): Biblioteka do sprawdzenia z jakiego kraju pochodzi adres IP lub domena |
1a528dee | 3 | Name: GeoIP |
0caf335f | 4 | Version: 1.5.1 |
01d8e1f7 | 5 | Release: 1 |
1bbf49d9 | 6 | License: GPL v2 |
1a528dee AG |
7 | Group: Libraries |
8 | Source0: http://www.maxmind.com/download/geoip/api/c/%{name}-%{version}.tar.gz | |
0caf335f | 9 | # Source0-md5: 36b82f3558e6e2ebdd11a56c5db21dbc |
accc8b5b | 10 | Patch0: %{name}-no_tests.patch |
0caf335f | 11 | Patch1: %{name}-pc.patch |
77d976d5 | 12 | # note: "c" is a filename, do not add '/' |
62adc71f | 13 | URL: http://www.maxmind.com/app/c |
4c9fcd03 | 14 | BuildRequires: autoconf >= 2.50 |
8a44bed0 JB |
15 | BuildRequires: automake |
16 | BuildRequires: libtool | |
db6d59ff | 17 | BuildRequires: zlib-devel |
db42c233 | 18 | Requires: %{name}-libs = %{version}-%{release} |
095d2529 | 19 | Requires: GeoIP-db-Country >= 2009.05.02 |
1a528dee AG |
20 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
21 | ||
22 | %description | |
7724721c AG |
23 | GeoIP is a C library that enables the user to find the country that |
24 | any IP address or hostname originates from. It uses a file based | |
25 | database that is accurate as of March 2003. This database simply | |
26 | contains IP blocks as keys, and countries as values. This database | |
27 | should be more complete and accurate than using reverse DNS lookups. | |
28 | Commercial databases and automatic update services are available from | |
095fef3a | 29 | <http://www.maxmind.com/>. |
1a528dee | 30 | |
8a44bed0 | 31 | This library can be used to automatically select the geographically |
7724721c AG |
32 | closest mirror, to analyze your web server logs to determine the |
33 | countries of your visitors, for credit card fraud detection, and for | |
34 | software export controls. | |
1a528dee | 35 | |
13e550ec JR |
36 | %description -l pl.UTF-8 |
37 | GeoIP jest biblioteką napisaną w C umożliwiającą użytkownikowi | |
38 | odnalezienie państwa, z którego pochodzi dany adres IP lub domena. | |
39 | Używa do tego zapisanej w pliku bazy danych (z marca 2003). W bazie | |
40 | tej adresy IP są kluczami, a państwa wartościami. Powinna ona być | |
41 | dokładniejsza niż sprawdzanie odwrotnego DNS. Komercyjne bazy oraz | |
42 | usługi automatycznych aktualizacji dostępne są na stronie | |
095fef3a | 43 | <http://www.maxmind.com/>. |
8a44bed0 | 44 | |
13e550ec JR |
45 | Ta biblioteka może być używana do automatycznego wyboru najbliższego |
46 | geograficznie mirrora, analizy logów serwera WWW w celu określenia | |
47 | kraju, z którego pochodzą odwiedzający, do wykrywania oszustw | |
48 | dotyczących kart kredytowych oraz kontroli eksportu oprogramowania. | |
8a44bed0 | 49 | |
db42c233 PG |
50 | %package libs |
51 | Summary: GeoIP Library | |
5d437b3a | 52 | Summary(pl.UTF-8): Biblioteka GeoIP |
db42c233 | 53 | Group: Libraries |
4b66015e | 54 | Conflicts: GeoIP < 1.4.0-2 |
db42c233 PG |
55 | |
56 | %description libs | |
57 | GeoIP library. | |
58 | ||
13e550ec | 59 | %description libs -l pl.UTF-8 |
db42c233 PG |
60 | Biblioteka GeoIP. |
61 | ||
8a44bed0 JB |
62 | %package devel |
63 | Summary: Header files for GeoIP library | |
5d437b3a | 64 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki GeoIP |
8a44bed0 | 65 | Group: Development/Libraries |
db42c233 | 66 | Requires: %{name}-libs = %{version}-%{release} |
8a44bed0 JB |
67 | |
68 | %description devel | |
69 | Header files for GeoIP library. | |
70 | ||
13e550ec JR |
71 | %description devel -l pl.UTF-8 |
72 | Pliki nagłówkowe biblioteki GeoIP. | |
8a44bed0 JB |
73 | |
74 | %package static | |
75 | Summary: Static GeoIP library | |
5d437b3a | 76 | Summary(pl.UTF-8): Statyczna biblioteka GeoIP |
8a44bed0 | 77 | Group: Development/Libraries |
095fef3a | 78 | Requires: %{name}-devel = %{version}-%{release} |
8a44bed0 JB |
79 | |
80 | %description static | |
81 | Static GeoIP library. | |
89616f82 | 82 | |
13e550ec | 83 | %description static -l pl.UTF-8 |
8a44bed0 | 84 | Statyczna biblioteka GeoIP. |
89616f82 | 85 | |
1a528dee AG |
86 | %prep |
87 | %setup -q | |
accc8b5b | 88 | %patch0 -p0 |
0caf335f | 89 | %patch1 -p1 |
1a528dee AG |
90 | |
91 | %build | |
8a44bed0 | 92 | %{__libtoolize} |
1a528dee AG |
93 | %{__aclocal} |
94 | %{__autoconf} | |
95 | %{__automake} | |
96 | %configure | |
97 | %{__make} | |
8a44bed0 | 98 | |
1a528dee AG |
99 | %{__make} check |
100 | ||
101 | %install | |
102 | rm -rf $RPM_BUILD_ROOT | |
1a528dee | 103 | |
1bbf49d9 MB |
104 | %{__make} install \ |
105 | DESTDIR=$RPM_BUILD_ROOT | |
4c9fcd03 JB |
106 | |
107 | %{__rm} $RPM_BUILD_ROOT%{_sysconfdir}/GeoIP.conf.default | |
1a528dee | 108 | |
69e7ed9b | 109 | # use GeoIP-db-Country package, which is updated more often (at least in PLD Linux) |
4c9fcd03 | 110 | %{__rm} $RPM_BUILD_ROOT%{_datadir}/GeoIP/GeoIP.dat |
69e7ed9b | 111 | |
1a528dee AG |
112 | %clean |
113 | rm -rf $RPM_BUILD_ROOT | |
114 | ||
77d976d5 JB |
115 | %post libs -p /sbin/ldconfig |
116 | %postun libs -p /sbin/ldconfig | |
1a528dee AG |
117 | |
118 | %files | |
119 | %defattr(644,root,root,755) | |
120 | %doc AUTHORS ChangeLog README TODO | |
4c9fcd03 JB |
121 | %attr(755,root,root) %{_bindir}/geoiplookup |
122 | %attr(755,root,root) %{_bindir}/geoiplookup6 | |
123 | %attr(755,root,root) %{_bindir}/geoipupdate | |
378958a1 | 124 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/GeoIP.conf |
4c9fcd03 JB |
125 | %{_mandir}/man1/geoiplookup.1* |
126 | %{_mandir}/man1/geoiplookup6.1* | |
127 | %{_mandir}/man1/geoipupdate.1* | |
8a44bed0 | 128 | |
db42c233 PG |
129 | %files libs |
130 | %defattr(644,root,root,755) | |
69e7ed9b | 131 | %attr(755,root,root) %{_libdir}/libGeoIP.so.*.*.* |
69e7ed9b | 132 | %attr(755,root,root) %ghost %{_libdir}/libGeoIP.so.1 |
4c9fcd03 | 133 | %attr(755,root,root) %{_libdir}/libGeoIPUpdate.so.*.*.* |
69e7ed9b ER |
134 | %attr(755,root,root) %ghost %{_libdir}/libGeoIPUpdate.so.0 |
135 | %dir %{_datadir}/%{name} | |
db42c233 | 136 | |
8a44bed0 JB |
137 | %files devel |
138 | %defattr(644,root,root,755) | |
4c9fcd03 JB |
139 | %attr(755,root,root) %{_libdir}/libGeoIP.so |
140 | %attr(755,root,root) %{_libdir}/libGeoIPUpdate.so | |
141 | %{_libdir}/libGeoIP.la | |
142 | %{_libdir}/libGeoIPUpdate.la | |
143 | %{_includedir}/GeoIP*.h | |
0caf335f | 144 | %{_pkgconfigdir}/geoip.pc |
8a44bed0 JB |
145 | |
146 | %files static | |
147 | %defattr(644,root,root,755) | |
4c9fcd03 JB |
148 | %{_libdir}/libGeoIP.a |
149 | %{_libdir}/libGeoIPUpdate.a |