]>
Commit | Line | Data |
---|---|---|
0f92866c | 1 | %define modname ssh2 |
93ebbc61 | 2 | %define status beta |
0f92866c ER |
3 | Summary: %{modname} - bindings for the libssh2 library |
4 | Summary(pl.UTF-8): %{modname} - dowiązania do biblioteki libssh2 | |
5 | Name: php-pecl-%{modname} | |
8fae05b2 JR |
6 | Version: 0.12 |
7 | Release: 1 | |
2903db35 | 8 | License: PHP |
45ecaa2e | 9 | Group: Development/Languages/PHP |
0f92866c | 10 | Source0: http://pecl.php.net/get/%{modname}-%{version}.tgz |
8fae05b2 JR |
11 | # Source0-md5: 409b91678a842bb0ff56f2cf018b9160 |
12 | Patch0: branch.diff | |
2903db35 | 13 | URL: http://pecl.php.net/package/ssh2/ |
8fae05b2 | 14 | BuildRequires: libssh2-devel >= 1.2.9 |
2903db35 | 15 | BuildRequires: openssl-devel >= 0.9.7d |
0f92866c | 16 | BuildRequires: php-devel >= 4:5.0.4 |
890c59dd | 17 | BuildRequires: rpmbuild(macros) >= 1.344 |
5486253a | 18 | %{?requires_php_extension} |
45ecaa2e AG |
19 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
20 | ||
45ecaa2e AG |
21 | %description |
22 | Provides bindings to the functions of libssh2 which implements the | |
23 | SSH2 protocol. | |
24 | ||
0f92866c | 25 | In PECL status of this extension is: %{status}. |
45ecaa2e | 26 | |
0313d4ea JR |
27 | %description -l pl.UTF-8 |
28 | Dostarcza dowiązań do różnych funkcji biblioteki libssh2 | |
29 | implementującej protokół SSH2. | |
45ecaa2e | 30 | |
0f92866c | 31 | To rozszerzenie ma w PECL status: %{status}. |
45ecaa2e AG |
32 | |
33 | %prep | |
0f92866c ER |
34 | %setup -qc |
35 | mv %{modname}-%{version}/* . | |
8fae05b2 | 36 | #%patch0 -p0 |
45ecaa2e AG |
37 | |
38 | %build | |
45ecaa2e AG |
39 | phpize |
40 | %configure | |
41 | %{__make} | |
42 | ||
43 | %install | |
44 | rm -rf $RPM_BUILD_ROOT | |
890c59dd | 45 | install -d $RPM_BUILD_ROOT{%{php_sysconfdir}/conf.d,%{php_extensiondir}} |
0f92866c ER |
46 | install -p modules/%{modname}.so $RPM_BUILD_ROOT%{php_extensiondir} |
47 | cat <<'EOF' > $RPM_BUILD_ROOT%{php_sysconfdir}/conf.d/%{modname}.ini | |
48 | ; Enable %{modname} extension module | |
49 | extension=%{modname}.so | |
5486253a | 50 | EOF |
45ecaa2e AG |
51 | |
52 | %clean | |
53 | rm -rf $RPM_BUILD_ROOT | |
54 | ||
55 | %post | |
890c59dd | 56 | %php_webserver_restart |
45ecaa2e | 57 | |
5486253a ER |
58 | %postun |
59 | if [ "$1" = 0 ]; then | |
890c59dd | 60 | %php_webserver_restart |
45ecaa2e AG |
61 | fi |
62 | ||
63 | %files | |
64 | %defattr(644,root,root,755) | |
0f92866c ER |
65 | %config(noreplace) %verify(not md5 mtime size) %{php_sysconfdir}/conf.d/%{modname}.ini |
66 | %attr(755,root,root) %{php_extensiondir}/%{modname}.so |