]> git.pld-linux.org Git - packages/php-pecl-xslcache.git/blob - php-pecl-xslcache.spec
support building for multiple php versions
[packages/php-pecl-xslcache.git] / php-pecl-xslcache.spec
1 %define         php_name        php%{?php_suffix}
2 %define         modname xslcache
3 Summary:        %{modname} - A modification of PHP's standard XSL extension that caches the parsed XSL stylesheet representation
4 Summary(pl.UTF-8):      %{modname} - modyfikacja standardowego rozszerzenia XSL PHP, które buforuje przetworzone reprezentacje arkuszów stylów XSL
5 Name:           %{php_name}-pecl-%{modname}
6 Version:        0.7.1
7 Release:        5
8 License:        PHP 3.01
9 Group:          Development/Languages/PHP
10 Source0:        http://pecl.php.net/get/%{modname}-%{version}.tgz
11 # Source0-md5:  1e32327f62122055ece6f78fa2b851b2
12 URL:            http://pecl.php.net/package/xslcache
13 BuildRequires:  libxslt-devel >= 1.1.0
14 BuildRequires:  %{php_name}-devel >= 3:5.0.0
15 BuildRequires:  rpmbuild(macros) >= 1.650
16 %{?requires_php_extension}
17 Requires:       php(core) >= 5.0.4
18 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
19
20 %description
21 The XSL Cache extension is a modification of PHP's standard XSL
22 extension that caches the parsed XSL stylesheet representation between
23 sessions for 2.5x boost in performance for sites that repeatedly apply
24 the same transform. Although there is still some further work that
25 could be done on the extension, this code is already proving
26 beneficial in production use for a few applications on the New York
27 Times' website.
28
29 %prep
30 %setup -q -c
31 mv %{modname}-%{version}/* .
32
33 %build
34 phpize
35 %configure \
36         --with-xslcache=%{_libdir} \
37         --with-xsl-exsl-dir=%{_libdir}
38 %{__make}
39
40 %install
41 rm -rf $RPM_BUILD_ROOT
42 install -d $RPM_BUILD_ROOT{%{php_sysconfdir}/conf.d,%{php_extensiondir}}
43
44 %{__make} install \
45         INSTALL_ROOT=$RPM_BUILD_ROOT \
46         EXTENSION_DIR=%{php_extensiondir}
47 cat <<'EOF' > $RPM_BUILD_ROOT%{php_sysconfdir}/conf.d/%{modname}.ini
48 ; Enable %{modname} extension module
49 extension=%{modname}.so
50 EOF
51
52 %clean
53 rm -rf $RPM_BUILD_ROOT
54
55 %post
56 %php_webserver_restart
57
58 %postun
59 if [ "$1" = 0 ]; then
60         %php_webserver_restart
61 fi
62
63 %files
64 %defattr(644,root,root,755)
65 %doc CREDITS
66 %config(noreplace) %verify(not md5 mtime size) %{php_sysconfdir}/conf.d/%{modname}.ini
67 %attr(755,root,root) %{php_extensiondir}/%{modname}.so
This page took 0.07972 seconds and 4 git commands to generate.