1 %define mod_name become
2 %define apxs %{_sbindir}/apxs
3 Summary: Apache module: Become Somebody
4 Name: apache-mod_%{mod_name}
8 Group: Networking/Daemons
9 Source0: http://www.snert.com/Software/mod_become/mod_become103.tgz
10 # Source0-md5: 7bb1607587687dabc711b3b1903947e5
11 URL: http://www.snert.com/Software/mod_become/
12 BuildRequires: apache(EAPI)-devel
13 Requires(post,preun): %{apxs}
14 Requires(post,preun): grep
15 Requires(preun): fileutils
16 Requires: apache(EAPI)
17 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
19 %define _pkglibdir %(%{apxs} -q LIBEXECDIR)
20 %define _sysconfdir /etc/httpd
23 This module enables the web server to take on the access rights of a
24 user & group, so that ~users can make available files to the web
25 without having to make them readable by the world on the local file
26 system. This can be useful for sites with a large number of users who
27 want to apply file access controls among themselves. This module can
28 also be applied to virtual hosts, directories, and locations.
31 %setup -q -n mod_%{mod_name}-%{version}
34 PATH=$PATH:%{_sbindir}
35 %{__make} build-dynamic
38 rm -rf $RPM_BUILD_ROOT
39 install -d $RPM_BUILD_ROOT{%{_pkglibdir},%{_sysconfdir}}
41 install mod_%{mod_name}.so $RPM_BUILD_ROOT%{_pkglibdir}
44 rm -rf $RPM_BUILD_ROOT
47 %{apxs} -e -a -n %{mod_name} %{_pkglibdir}/mod_%{mod_name}.so 1>&2
50 if [ "$1" = "0" ]; then
51 %{apxs} -e -A -n %{mod_name} %{_pkglibdir}/mod_%{mod_name}.so 1>&2
52 if [ -f /var/lock/subsys/httpd ]; then
53 /etc/rc.d/init.d/httpd restart 1>&2
58 %defattr(644,root,root,755)
59 %doc CHANGES.txt LICENSE.txt SECURITY.txt index.shtml notes-conf.txt
60 %attr(755,root,root) %{_pkglibdir}/*