]> git.pld-linux.org Git - packages/apache-mod_suid2.git/commitdiff
- unified
authorElan Ruusamäe <glen@pld-linux.org>
Tue, 27 Dec 2005 00:51:00 +0000 (00:51 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    apache-mod_suid2.spec -> 1.7

apache-mod_suid2.spec

index d97b63c280fbbfa6d25a26e5bc6666283bf62dae..39ee68ac4ed8b60754a534b9bf550a0f2ad442a3 100644 (file)
@@ -14,11 +14,11 @@ Patch1:             %{name}-groups.patch
 URL:           http://bluecoara.net/servers/apache/mod_suid2_en.phtml
 BuildRequires: %{apxs}
 BuildRequires: apache-devel >= 2.0.0
-Requires(post,preun):  %{apxs}
-Requires:      apache
+Requires:      apache(modules-api) = %apache_modules_api
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
-%define                _pkglibdir      %(%{apxs} -q LIBEXECDIR)
+%define                _pkglibdir      %(%{apxs} -q LIBEXECDIR 2>/dev/null)
+%define                _sysconfdir     %(%{apxs} -q SYSCONFDIR 2>/dev/null)
 
 %description
 Apache module: execution of scripts under their own uids per-vhost.
@@ -36,14 +36,29 @@ Modu
 
 %install
 rm -rf $RPM_BUILD_ROOT
-install -d $RPM_BUILD_ROOT%{_pkglibdir}
+install -d $RPM_BUILD_ROOT{%{_pkglibdir},%{_sysconfdir}/httpd.conf}
 
 install .libs/mod_%{mod_name}.so $RPM_BUILD_ROOT%{_pkglibdir}
+echo 'LoadModule %{mod_name}_module modules/mod_%{mod_name}.so' > \
+       $RPM_BUILD_ROOT%{_sysconfdir}/httpd.conf/90_mod_%{mod_name}.conf
 
 %clean
 rm -rf $RPM_BUILD_ROOT
 
+%post
+if [ -f /var/lock/subsys/httpd ]; then
+       /etc/rc.d/init.d/httpd restart 1>&2
+fi
+
+%preun
+if [ "$1" = "0" ]; then
+       if [ -f /var/lock/subsys/httpd ]; then
+               /etc/rc.d/init.d/httpd restart 1>&2
+       fi
+fi
+
 %files
 %defattr(644,root,root,755)
 %doc CHANGES
+%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/httpd.conf/*_mod_%{mod_name}.conf
 %attr(755,root,root) %{_pkglibdir}/*.so
This page took 0.079176 seconds and 4 git commands to generate.