]>
Commit | Line | Data |
---|---|---|
d7658115 AG |
1 | %define _modname statgrab |
2 | %define _smodname Statgrab | |
a4cf29f5 | 3 | %define _status stable |
d7658115 | 4 | Summary: %{_modname} - libstatgrab bindings |
2c3979c5 | 5 | Summary(pl.UTF-8): %{_modname} - dowiązania biblioteki libstatgrab |
d7658115 | 6 | Name: php-pecl-%{_modname} |
a4cf29f5 | 7 | Version: 0.6.0 |
6d6e9be2 | 8 | Release: 2 |
d7658115 AG |
9 | License: PHP |
10 | Group: Development/Languages/PHP | |
11 | Source0: http://pecl.php.net/get/%{_modname}-%{version}.tgz | |
a4cf29f5 | 12 | # Source0-md5: 5e8e659e28d95da57c3d5a694cfb5af4 |
d7658115 | 13 | URL: http://pecl.php.net/package/statgrab/ |
549e7d79 | 14 | BuildRequires: libstatgrab-devel >= 0.10 |
ffb851d4 | 15 | BuildRequires: php-devel >= 3:5.0.0 |
36f537a7 | 16 | BuildRequires: rpmbuild(macros) >= 1.344 |
ffb851d4 | 17 | %{?requires_php_extension} |
36f537a7 | 18 | Requires: php-common >= 4:5.0.4 |
d7658115 AG |
19 | Obsoletes: php-pear-%{_modname} |
20 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
21 | ||
d7658115 | 22 | %description |
33c05ef2 JB |
23 | libstatgrab is a library that provides a common interface for |
24 | retrieving a variety of system statistics on a number of *NIX like | |
25 | systems. | |
d7658115 | 26 | |
33c05ef2 | 27 | This extension allows you to call the functions made available by |
94f7e8fa | 28 | libstatgrab library. |
d7658115 | 29 | |
1406a801 | 30 | In PECL status of this package is: %{_status}. |
d7658115 | 31 | |
2c3979c5 JR |
32 | %description -l pl.UTF-8 |
33 | libstatgrab to biblioteka dostarczająca wspólny interfejs do | |
34 | odczytywania różnych statystyk systemowych na wielu systemach | |
33c05ef2 JB |
35 | uniksowych. |
36 | ||
2c3979c5 JR |
37 | To rozszerzenie pozwala wywoływać funkcje udostępniane przez |
38 | bibliotekę libstatgrab. | |
d7658115 | 39 | |
1406a801 | 40 | To rozszerzenie ma w PECL status: %{_status}. |
d7658115 AG |
41 | |
42 | %prep | |
43 | %setup -q -c | |
44 | ||
45 | %build | |
46 | cd %{_smodname}-%{version} | |
47 | phpize | |
48 | %configure | |
49 | %{__make} | |
50 | ||
51 | %install | |
52 | rm -rf $RPM_BUILD_ROOT | |
36f537a7 | 53 | install -d $RPM_BUILD_ROOT{%{php_sysconfdir}/conf.d,%{php_extensiondir}} |
d7658115 | 54 | |
36f537a7 ER |
55 | install %{_smodname}-%{version}/modules/%{_modname}.so $RPM_BUILD_ROOT%{php_extensiondir} |
56 | cat <<'EOF' > $RPM_BUILD_ROOT%{php_sysconfdir}/conf.d/%{_modname}.ini | |
ffb851d4 ER |
57 | ; Enable %{_modname} extension module |
58 | extension=%{_modname}.so | |
59 | EOF | |
d7658115 AG |
60 | |
61 | %clean | |
62 | rm -rf $RPM_BUILD_ROOT | |
63 | ||
64 | %post | |
36f537a7 | 65 | %php_webserver_restart |
d7658115 | 66 | |
ffb851d4 ER |
67 | %postun |
68 | if [ "$1" = 0 ]; then | |
36f537a7 | 69 | %php_webserver_restart |
d7658115 AG |
70 | fi |
71 | ||
72 | %files | |
73 | %defattr(644,root,root,755) | |
74 | %doc %{_smodname}-%{version}/CREDITS | |
36f537a7 ER |
75 | %config(noreplace) %verify(not md5 mtime size) %{php_sysconfdir}/conf.d/%{_modname}.ini |
76 | %attr(755,root,root) %{php_extensiondir}/%{_modname}.so |