]>
Commit | Line | Data |
---|---|---|
430cabea AG |
1 | %define _modname stats |
2 | %define _status stable | |
3 | %define _sysconfdir /etc/php4 | |
4 | %define extensionsdir %(php-config --extension-dir 2>/dev/null) | |
430cabea | 5 | Summary: %{_modname} - extension with routines for statistical computation |
a35da396 | 6 | Summary(pl.UTF-8): %{_modname} - rozszerzenie z funkcjami do wykonywania obliczeń statystycznych |
430cabea | 7 | Name: php4-pecl-%{_modname} |
0b25e1cf | 8 | Version: 1.0.2 |
430cabea AG |
9 | Release: 1 |
10 | License: PHP 2.02 | |
11 | Group: Development/Languages/PHP | |
12 | Source0: http://pecl.php.net/get/%{_modname}-%{version}.tgz | |
0b25e1cf | 13 | # Source0-md5: 96f105be1e76fbc5dca424057066e4d8 |
430cabea AG |
14 | URL: http://pecl.php.net/package/stats/ |
15 | BuildRequires: php4-devel >= 3:4.3.0 | |
cef1272c ER |
16 | BuildRequires: rpmbuild(macros) >= 1.344 |
17 | Requires: php4-common >= 3:4.4.0-3 | |
430cabea | 18 | %{?requires_php_extension} |
430cabea AG |
19 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
20 | ||
21 | %description | |
22 | Extension that provides few dozens routines for statistical | |
23 | computation, such as stats_absolute_deviation(), stats_covariance(), | |
24 | harmonic_mean() and others. | |
25 | ||
26 | In PECL status of this extension is: %{_status}. | |
27 | ||
2ad548b5 JR |
28 | %description -l pl.UTF-8 |
29 | To rozszerzenie dostarcza wiele różnych funkcji do wykonywania | |
30 | obliczeń statystycznych, takich jak stats_absolute_deviation(), | |
430cabea AG |
31 | stats_covariance(), harmonic_mean() i inne. |
32 | ||
33 | To rozszerzenie ma w PECL status: %{_status}. | |
34 | ||
35 | %prep | |
36 | %setup -q -c | |
37 | ||
38 | %build | |
39 | cd %{_modname}-%{version} | |
40 | phpize | |
41 | %configure | |
42 | %{__make} | |
43 | ||
44 | %install | |
45 | rm -rf $RPM_BUILD_ROOT | |
46 | install -d $RPM_BUILD_ROOT{%{_sysconfdir}/conf.d,%{extensionsdir}} | |
47 | ||
48 | install %{_modname}-%{version}/modules/%{_modname}.so $RPM_BUILD_ROOT%{extensionsdir} | |
49 | cat <<'EOF' > $RPM_BUILD_ROOT%{_sysconfdir}/conf.d/%{_modname}.ini | |
50 | ; Enable %{_modname} extension module | |
51 | extension=%{_modname}.so | |
52 | EOF | |
53 | ||
54 | %clean | |
55 | rm -rf $RPM_BUILD_ROOT | |
56 | ||
57 | %post | |
cef1272c | 58 | %php4_webserver_restart |
430cabea AG |
59 | |
60 | %postun | |
61 | if [ "$1" = 0 ]; then | |
cef1272c | 62 | %php4_webserver_restart |
430cabea AG |
63 | fi |
64 | ||
65 | %files | |
66 | %defattr(644,root,root,755) | |
67 | %doc %{_modname}-%{version}/{CREDITS,TODO} | |
68 | %doc %{_modname}-%{version}/tests | |
69 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/conf.d/%{_modname}.ini | |
70 | %attr(755,root,root) %{extensionsdir}/%{_modname}.so |