]> git.pld-linux.org Git - packages/php-pecl-APC.git/blob - php-pecl-APC.spec
- ./adapter -s
[packages/php-pecl-APC.git] / php-pecl-APC.spec
1 %define         _modname        APC
2 %define         _status         stable
3 %define         _sysconfdir     /etc/php
4 %define         extensionsdir   %(php-config --extension-dir 2>/dev/null)
5
6 Summary:        %{_modname} - Alternative PHP Cache
7 Summary(pl):    %{_modname} - alternatywne cache PHP
8 Name:           php-pecl-%{_modname}
9 Version:        3.0.8
10 Release:        2
11 License:        PHP
12 Group:          Development/Languages/PHP
13 Source0:        http://pecl.php.net/get/%{_modname}-%{version}.tgz
14 # Source0-md5:  a70a14a00275e551e8085f742322433f
15 URL:            http://pecl.php.net/package/APC/
16 BuildRequires:  php-devel >= 3:5.0.0
17 BuildRequires:  rpmbuild(macros) >= 1.230
18 %requires_eq_to php-common php-devel
19 Requires:       %{_sysconfdir}/conf.d
20 Obsoletes:      php-pear-%{_modname}
21 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
22
23 %description
24 APC is the Alternative PHP Cache. It was conceived of to provide a
25 free, open, and robust framework for caching and optimizing PHP
26 intermediate code.
27
28 In PECL status of this package is: %{_status}.
29
30 %description -l pl
31 APC to alternatywne cache PHP. W wyobra¿eniach mia³o dostarczaæ
32 wolnodostêpny, otwarty i potê¿ny szkielet do buforowania i
33 optymalizowania kodu po¶redniego PHP.
34
35 To rozszerzenie ma w PECL status: %{_status}.
36
37 %prep
38 %setup -q -c
39
40 %build
41 cd %{_modname}-%{version}
42 phpize
43 %configure
44 %{__make}
45
46 %install
47 rm -rf $RPM_BUILD_ROOT
48 install -d $RPM_BUILD_ROOT{%{_sysconfdir}/conf.d,%{extensionsdir}}
49
50 install %{_modname}-%{version}/modules/apc.so $RPM_BUILD_ROOT%{extensionsdir}/%{_modname}.so
51 cat <<'EOF' > $RPM_BUILD_ROOT%{_sysconfdir}/conf.d/%{_modname}.ini
52 ; Enable %{_modname} extension module
53 extension=%{_modname}.so
54 EOF
55
56 %clean
57 rm -rf $RPM_BUILD_ROOT
58
59 %post
60 [ ! -f /etc/apache/conf.d/??_mod_php.conf ] || %service -q apache restart
61 [ ! -f /etc/httpd/httpd.conf/??_mod_php.conf ] || %service -q httpd restart
62
63 %postun
64 if [ "$1" = 0 ]; then
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
67 fi
68
69 %files
70 %defattr(644,root,root,755)
71 %doc %{_modname}-%{version}/{CHANGELOG,INSTALL,NOTICE}
72 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/conf.d/%{_modname}.ini
73 %attr(755,root,root) %{extensionsdir}/%{_modname}.so
This page took 0.062914 seconds and 4 git commands to generate.