]> git.pld-linux.org Git - packages/apache-mod_mpm_itk.git/blob - apache-mod_mpm_itk.spec
- rel 3; use /var/run/php/ug for php session files
[packages/apache-mod_mpm_itk.git] / apache-mod_mpm_itk.spec
1 %define         mod_name        mpm_itk
2 %define         apxs            /usr/sbin/apxs
3 %define         ver     2.4.7
4 %define         subver  02
5 Summary:        mod_mpm_itk - allows you to run each of your vhost under a separate uid and gid
6 Name:           apache-mod_mpm_itk
7 Version:        %{ver}.%{subver}
8 Release:        3
9 License:        Apache v2.0
10 Group:          Networking/Daemons/HTTP
11 Source0:        http://mpm-itk.sesse.net/mpm-itk-%{ver}-%{subver}.tar.gz
12 # Source0-md5:  241eddeef8d3931c6699a51d5d2169a7
13 Source1:        %{name}.conf
14 Source2:        %{name}-php.conf
15 URL:            http://mpm-itk.sesse.net/
16 BuildRequires:  %{apxs}
17 BuildRequires:  apache-devel >= 2.4.7
18 BuildRequires:  apr-devel >= 1:1.0
19 BuildRequires:  apr-util-devel >= 1:1.0
20 BuildRequires:  libcap-devel
21 Requires:       apache(modules-api) = %{apache_modules_api}
22 Requires:       apache-base >= 2.4.7
23 Requires:       php-dirs
24 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
25
26 %define         _pkglibdir      %(%{apxs} -q LIBEXECDIR 2>/dev/null)
27 %define         _sysconfdir     %(%{apxs} -q SYSCONFDIR 2>/dev/null)
28
29 %description
30 apache2-mpm-itk (just mpm-itk for short) is an MPM (Multi-Processing
31 Module) for the Apache web server. mpm-itk allows you to run each of
32 your vhost under a separate uid and gid - in short, the scripts and
33 configuration files for one vhost no longer have to be readable for
34 all the other vhosts.
35
36 mpm-itk is based on the traditional prefork MPM, which means it's
37 non-threaded; in short, this means you can run non-thread-aware code
38 (like many PHP extensions) without problems. On the other hand, you
39 lose out to any performance benefit you'd get with threads, of course;
40 you'd have to decide for yourself if that's worth it or not. You will
41 also take an additional performance hit over prefork, since there's an
42 extra fork per request.
43
44 %define no_install_post_check_tmpfiles  1
45
46 %prep
47 %setup -q -n mpm-itk-%{ver}-%{subver}
48
49 %build
50 %configure \
51         --with-apxs=%{apxs}
52 %{__make}
53
54 %install
55 rm -rf $RPM_BUILD_ROOT
56 install -d $RPM_BUILD_ROOT{%{_sbindir},%{_pkglibdir},%{_sysconfdir}/conf.d}
57 install -d $RPM_BUILD_ROOT/var/run/php/ug
58
59 install -p .libs/mpm_itk.so $RPM_BUILD_ROOT%{_pkglibdir}
60 cp -p %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/conf.d/10_mod_%{mod_name}.conf
61 cp -p %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/conf.d/99_mod_%{mod_name}-php.conf
62
63 %clean
64 rm -rf $RPM_BUILD_ROOT
65
66 %post
67 %service -q httpd restart
68
69 %postun
70 if [ "$1" = "0" ]; then
71         %service -q httpd restart
72 fi
73
74 %files
75 %defattr(644,root,root,755)
76 %doc CHANGES README
77 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/conf.d/*_mod_%{mod_name}.conf
78 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/conf.d/*_mod_%{mod_name}-php.conf
79 %attr(755,root,root) %{_pkglibdir}/mpm_itk.so
80 # multiple uid/gids in use
81 %dir %attr(1773,root,root) /var/run/php/ug
82
This page took 0.048145 seconds and 3 git commands to generate.