3 %define _sysconfdir /etc/php
4 %define extensionsdir %(php-config --extension-dir 2>/dev/null)
5 Summary: %{_modname} - event scheduling engine
6 Summary(pl): %{_modname} - silnik do planowania zdarzeñ
7 Name: php-pecl-%{_modname}
11 Group: Development/Languages/PHP
12 Source0: http://pecl.php.net/get/%{_modname}-%{version}.tgz
13 # Source0-md5: f009fd3519c14a027a8c85414208b61c
14 URL: http://pecl.php.net/package/event/
15 BuildRequires: php-devel >= 3:5.0.0
16 BuildRequires: rpmbuild(macros) >= 1.254
17 %{?requires_php_extension}
18 Requires: %{_sysconfdir}/conf.d
19 Obsoletes: php-pear-%{_modname}
20 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
23 This is an extension to efficiently schedule IO, time and signal based
24 events using the best available IO notification mechanism for your
27 This is a port of libevent to the PHP infrastructure; the API is
28 similar but not identical.
30 In PECL status of this extension is: %{_status}.
33 To rozszerzenie pozwala na efektywne planowanie We/Wy, czasu oraz
34 opartych na sygna³ach zdarzeñ za pomoc± najlepszego dostêpnego dla
35 systemu mechanizmu powiadamiania.
37 Jest to port biblioteki libevent do infrastruktury PHP; API jest
38 podobne, jednak nie identyczne.
40 To rozszerzenie ma w PECL status: %{_status}.
46 cd %{_modname}-%{version}
52 rm -rf $RPM_BUILD_ROOT
53 install -d $RPM_BUILD_ROOT{%{_sysconfdir}/conf.d,%{extensionsdir}}
55 install %{_modname}-%{version}/modules/%{_modname}.so $RPM_BUILD_ROOT%{extensionsdir}
56 cat <<'EOF' > $RPM_BUILD_ROOT%{_sysconfdir}/conf.d/%{_modname}.ini
57 ; Enable %{_modname} extension module
58 extension=%{_modname}.so
62 rm -rf $RPM_BUILD_ROOT
65 [ ! -f /etc/apache/conf.d/??_mod_php.conf ] || %service -q apache restart
66 [ ! -f /etc/httpd/httpd.conf/??_mod_php.conf ] || %service -q httpd restart
70 [ ! -f /etc/apache/conf.d/??_mod_php.conf ] || %service -q apache restart
71 [ ! -f /etc/httpd/httpd.conf/??_mod_php.conf ] || %service -q httpd restart
75 %defattr(644,root,root,755)
76 %doc %{_modname}-%{version}/{CREDITS,EXPERIMENTAL}
77 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/conf.d/%{_modname}.ini
78 %attr(755,root,root) %{extensionsdir}/%{_modname}.so