2 # - move tmpwatch S: to php-session package (as session files file storage no
3 # longer can cleanup itself due dir perms)
4 # - https://fedorahosted.org/tmpwatch/ticket/7 is implemented in tmpwatch-2.9.16, see 3467603 todo
5 Summary: Common dirs for PHP
6 Summary(pl.UTF-8): Wspólne katalogi dla PHP
12 Source0: php-session.sh
13 Source1: %{name}.tmpfiles
15 BuildRequires: rpmbuild(macros) >= 1.644
16 Requires(postun): /usr/sbin/groupdel
17 Requires(pre): /usr/bin/getgid
18 Requires(pre): /usr/sbin/groupadd
20 Conflicts: php-pear < 4:1.4-2
23 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
25 %define _libexecdir %{_prefix}/lib
28 Common directories for PHP.
30 %description -l pl.UTF-8
31 Wspólne katalogi dla PHP.
36 rm -rf $RPM_BUILD_ROOT
37 install -d $RPM_BUILD_ROOT{/etc/cron.d,/var/{cache,log,run}/php,/var/log/archive/php} \
38 $RPM_BUILD_ROOT%{_docdir}/phpdoc \
39 $RPM_BUILD_ROOT%{_libexecdir} \
40 $RPM_BUILD_ROOT%{systemdtmpfilesdir}
42 install -p %{SOURCE0} $RPM_BUILD_ROOT%{_libexecdir}
43 cp -p %{SOURCE1} $RPM_BUILD_ROOT%{systemdtmpfilesdir}/%{name}.conf
44 cp -p %{SOURCE2} $RPM_BUILD_ROOT/etc/cron.d/php-session
47 install -d $RPM_BUILD_ROOT$dir
50 %{php_data_dir}/Symfony/Bridge
51 %{php_data_dir}/Symfony/Component
55 rm -rf $RPM_BUILD_ROOT
61 if [ "$1" = "0" ]; then
66 %defattr(644,root,root,755)
67 %config(noreplace) %verify(not md5 mtime size) /etc/cron.d/php-session
68 %{systemdtmpfilesdir}/%{name}.conf
69 %attr(755,root,root) %{_libexecdir}/php-session.sh
72 %dir %{_docdir}/phpdoc
73 %attr(775,root,http) %dir %verify(not group mode) /var/log/php
74 %attr(770,root,root) %dir %verify(not group mode) /var/log/archive/php
76 # no +r, so only predictable names can be used. currently php-soap wsdl cache is there
77 %attr(730,root,http) %dir %verify(not group mode) /var/cache/php
79 # http needs only +x for directory
80 # (otherwise it knows session file names and can read it contents)
81 # keep o+x for fcgi.sock (lighttpd)
82 %attr(731,root,http) %dir %verify(not group mode) /var/run/php