]> git.pld-linux.org Git - packages/php-pecl-big_int.git/blame - php-pecl-big_int.spec
support multiple php versions
[packages/php-pecl-big_int.git] / php-pecl-big_int.spec
CommitLineData
d0e12035
ER
1%define php_name php%{?php_suffix}
2%define modname big_int
3%define status stable
4Summary: %{modname} - set of functions for calculations with arbitrary length integers
5Summary(pl.UTF-8): %{modname} - zestaw funkcji do obliczeń z użyciem liczb o dowolnej wielkości
6Name: %{php_name}-pecl-%{modname}
959f9e1b 7Version: 1.0.7
e8cb9ad9 8Release: 2
5a9f3233
AG
9License: PHP 2.02
10Group: Development/Languages/PHP
d0e12035 11Source0: http://pecl.php.net/get/%{modname}-%{version}.tgz
959f9e1b 12# Source0-md5: d858d5bcfd3f789cb1ae8cb8ff09d3e9
5a9f3233 13URL: http://pecl.php.net/package/big_int/
d0e12035
ER
14BuildRequires: %{php_name}-devel >= 3:5.0.0
15BuildRequires: rpmbuild(macros) >= 1.650
8a887a5a 16%{?requires_php_extension}
d0e12035
ER
17Requires: php(core) >= 5.0.4
18Obsoletes: php-pear-%{modname}
5a9f3233
AG
19BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
20
5a9f3233 21%description
18ddb9de
JB
22This package is useful for number theory applications. For example, in
23two-keys cryptography. See tests/RSA.php in the package for example of
24implementation of RSA-like cryptoalgorithm.
5a9f3233
AG
25
26Also the package has many bitset functions, which allow to work with
27arbitrary length bitsets.
28
18ddb9de
JB
29This package is much faster than bundled into PHP BCMath. It
30implements almost all functions as in GMP extension, but it needn't
31any additional external libraries.
5a9f3233 32
d0e12035 33In PECL status of this extension is: %{status}.
5a9f3233 34
a95e8e68
JR
35%description -l pl.UTF-8
36Ten pakiet jest przydatny do zastosowań z teorii liczb, na przykład do
37kryptografii z użyciem dwóch kluczy. Przykładową implementację
38algorytmu kryptograficznego podobnego do RSA można znaleźć w tym
18ddb9de
JB
39pakiecie w pliku tests/RSA.php.
40
a95e8e68
JR
41Pakiet ma także wiele funkcji operujących na bitach, umożliwiających
42działanie na zbiorach bitów dowolnej długości.
18ddb9de 43
a95e8e68
JR
44Ten pakiet jest dużo szybszy niż wbudowany w PHP BCMath. Implementuje
45prawie wszystkie funkcje z rozszerzenia GMP, ale nie wymaga żadnych
46dodatkowych bibliotek zewnętrznych.
18ddb9de 47
d0e12035 48To rozszerzenie ma w PECL status: %{status}.
5a9f3233
AG
49
50%prep
d0e12035
ER
51%setup -qc
52mv %{modname}-%{version}/* .
5a9f3233
AG
53
54%build
5a9f3233
AG
55phpize
56%configure
57%{__make}
58
59%install
60rm -rf $RPM_BUILD_ROOT
372e1176 61install -d $RPM_BUILD_ROOT{%{php_sysconfdir}/conf.d,%{php_extensiondir}}
d0e12035
ER
62install -p modules/%{modname}.so $RPM_BUILD_ROOT%{php_extensiondir}
63cat <<'EOF' > $RPM_BUILD_ROOT%{php_sysconfdir}/conf.d/%{modname}.ini
64; Enable %{modname} extension module
65extension=%{modname}.so
2d181cf1 66EOF
5a9f3233
AG
67
68%clean
69rm -rf $RPM_BUILD_ROOT
70
71%post
372e1176 72%php_webserver_restart
5a9f3233 73
2d181cf1
ER
74%postun
75if [ "$1" = 0 ]; then
372e1176 76 %php_webserver_restart
5a9f3233
AG
77fi
78
79%files
80%defattr(644,root,root,755)
d0e12035
ER
81%doc CREDITS README docs tests
82%config(noreplace) %verify(not md5 mtime size) %{php_sysconfdir}/conf.d/%{modname}.ini
83%attr(755,root,root) %{php_extensiondir}/%{modname}.so
This page took 0.700833 seconds and 4 git commands to generate.