1 %define _modname xcache
2 Summary: %{_modname} - PHP opcode cacher
3 Summary(pl.UTF-8): %{_modname} - buforowanie opcodów PHP
8 Group: Development/Languages/PHP
9 URL: http://xcache.lighttpd.net/
10 Source0: http://210.51.190.228/pub/XCache/Releases/xcache-%{version}.tar.bz2
11 # Source0-md5: ffeaa9547037e098d9b041eb9741b51e
12 Patch0: xcache-m4.patch
13 BuildRequires: php-devel >= 3:5.1
14 BuildRequires: rpmbuild(macros) >= 1.344
15 BuildRequires: sed >= 4.0
16 %{?requires_zend_extension}
17 Requires: php-common >= 4:5.0.4
18 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
21 XCache is a fast, stable PHP opcode cacher that has been tested and is
22 now running on production servers under high load.
24 %description -l pl.UTF-8
25 XCache to szybkie, stabilne buforowanie opcodów PHP, przetestowane i
26 działające na produkcyjnych serwerach o dużym obciążeniu.
32 s,zend_extension =.*,zend_extension = %{php_extensiondir}/xcache.so,
33 s,zend_extension_ts = .*,zend_extension_ts = %{php_extensiondir}/xcache.so,
40 --enable-xcache-optimizer \
41 --enable-xcache-coverager
45 rm -rf $RPM_BUILD_ROOT
46 install -d $RPM_BUILD_ROOT%{php_sysconfdir}/conf.d
49 INSTALL_ROOT=$RPM_BUILD_ROOT
51 # The cache directory where pre-compiled files will reside
52 install -d $RPM_BUILD_ROOT/var/cache/php-xcache
53 install -d $RPM_BUILD_ROOT%{_datadir}/xcache
55 # Drop in the bit of configuration
56 install xcache.ini $RPM_BUILD_ROOT%{php_sysconfdir}/conf.d/%{_modname}.ini
57 install -D admin/* $RPM_BUILD_ROOT%{_datadir}/xcache
60 rm -rf $RPM_BUILD_ROOT
63 %php_webserver_restart
67 %php_webserver_restart
71 %defattr(644,root,root,755)
72 %doc AUTHORS README THANKS
73 %config(noreplace) %verify(not md5 mtime size) %{php_sysconfdir}/conf.d/%{_modname}.ini
74 %attr(755,root,root) %{php_extensiondir}/%{_modname}.so
76 %dir %attr(775,root,http) /var/cache/php-xcache