]> git.pld-linux.org Git - packages/php-pecl-geoip.git/blame - php-pecl-geoip.spec
- php 5.5 rebuild
[packages/php-pecl-geoip.git] / php-pecl-geoip.spec
CommitLineData
4ebafef4 1%define php_name php%{?php_suffix}
94d4fff2
ER
2%define modname geoip
3%define status status
4Summary: %{modname} - Map IP address to geographic places
5Summary(pl.UTF-8): %{modname} - odwzorowanie adresów IP w miejsca geograficzne
4ebafef4 6Name: %{php_name}-pecl-%{modname}
94d4fff2 7Version: 1.0.8
323a8a28 8Release: 7
50458e99 9License: PHP 3.01
340a992b 10Group: Development/Languages/PHP
94d4fff2
ER
11Source0: http://pecl.php.net/get/%{modname}-%{version}.tgz
12# Source0-md5: 65263ac6d1c335f22ce818b3253912a5
5a37c5f3 13Patch0: find_libgeoip.patch
340a992b 14URL: http://pecl.php.net/package/geoip/
4ebafef4 15BuildRequires: %{php_name}-devel >= 3:5.0.0
a664283f 16BuildRequires: GeoIP-devel >= 1.4.0
4ebafef4 17BuildRequires: rpmbuild(macros) >= 1.650
95f3eede
ER
18Suggests: GeoIP-db-City
19Suggests: GeoIP-db-Country
20Suggests: GeoIP-db-IPASNum
340a992b 21%{?requires_php_extension}
68cebe85 22Requires: php(core) >= 5.0.4
27e3a0b1 23Provides: php(geoip) = %{version}
340a992b
AG
24BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
25
26%description
27This PHP extension allows you to find the location of an IP address -
28City, State, Country, Longitude, Latitude, and other information as
29all, such as ISP and connection type.
30
94d4fff2 31In PECL status of this extension is: %{status}.
340a992b 32
726c40a9
JR
33%description -l pl.UTF-8
34To rozszerzenie pozwala na znalezienie miejsca, któremu odpowiada dany
35adres IP - miasto, stan, kraj, szerokość i długość geograficzna czy
36inne informacje, takie jak ISP czy typ połączenia.
340a992b 37
94d4fff2 38To rozszerzenie ma w PECL status: %{status}.
340a992b
AG
39
40%prep
94d4fff2
ER
41%setup -qc
42mv %{modname}-%{version}/* .
5a37c5f3 43%patch0 -p1
340a992b 44
94d4fff2 45sed -i -e 's,GEOIP_DIR/lib,GEOIP_DIR/%{_lib},g' config.m4
bcf09fbb 46
340a992b 47%build
340a992b
AG
48phpize
49%configure
50%{__make}
51
52%install
53rm -rf $RPM_BUILD_ROOT
340a992b 54%{__make} install \
94d4fff2
ER
55 EXTENSION_DIR=%{php_extensiondir} \
56 INSTALL_ROOT=$RPM_BUILD_ROOT
57
58install -d $RPM_BUILD_ROOT%{php_sysconfdir}/conf.d
59cat <<'EOF' > $RPM_BUILD_ROOT%{php_sysconfdir}/conf.d/%{modname}.ini
60; Enable %{modname} extension module
61extension=%{modname}.so
340a992b
AG
62EOF
63
64%clean
65rm -rf $RPM_BUILD_ROOT
66
67%post
1bc96849 68%php_webserver_restart
340a992b
AG
69
70%postun
71if [ "$1" = 0 ]; then
1bc96849 72 %php_webserver_restart
340a992b
AG
73fi
74
75%files
76%defattr(644,root,root,755)
94d4fff2
ER
77%doc README ChangeLog
78%config(noreplace) %verify(not md5 mtime size) %{php_sysconfdir}/conf.d/%{modname}.ini
79%attr(755,root,root) %{php_extensiondir}/%{modname}.so
This page took 0.063481 seconds and 4 git commands to generate.