Name: apache-mod_%{mod_name}
# NOTE: remember about apache1-mod_fastcgi.spec when messing here
Version: 2.4.2
-Release: 5
+Release: 6
License: distributable
Group: Networking/Daemons
Source0: http://www.FastCGI.com/dist/mod_%{mod_name}-%{version}.tar.gz
# Source0-md5: e994414304b535cb99e10b7d1cad1d1e
Patch0: %{name}-apr1.patch
Patch1: %{name}-allow-uid-gid.patch
+Patch2: %{name}-socketdir.patch
Source1: %{name}.conf
URL: http://www.FastCGI.com/
BuildRequires: %{apxs}
%define _sysconfdir %(%{apxs} -q SYSCONFDIR)
%define _pkglibdir %(%{apxs} -q LIBEXECDIR)
+# FIXME /var/run/httpd, but apache.spec owns /var/run/apache, so fix there first.
+%define _socketdir /var/run/apache/fastcgi
%description
This 3rd party module provides support for the FastCGI protocol.
%setup -q -n mod_%{mod_name}-%{version}
%patch0 -p1
%patch1 -p1
+%patch2 -p1
%build
%{__make} -f Makefile.AP2 \
%install
rm -rf $RPM_BUILD_ROOT
-install -d $RPM_BUILD_ROOT{%{_pkglibdir},%{_sysconfdir}/httpd.conf}
+install -d $RPM_BUILD_ROOT{%{_pkglibdir},%{_sysconfdir}/httpd.conf,%{_socketdir}/dynamic}
install .libs/mod_%{mod_name}.so $RPM_BUILD_ROOT%{_pkglibdir}
install %{SOURCE1} $RPM_BUILD_ROOT/%{_sysconfdir}/httpd.conf/
else
echo "Run \"/etc/rc.d/init.d/httpd start\" to start apache HTTP daemon."
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 docs/LICENSE.TERMS CHANGES docs/*.html
%attr(755,root,root) %{_pkglibdir}/*.so
%config %{_sysconfdir}/httpd.conf/*.conf
+%dir %attr(770,root,http) %{_socketdir}
+%dir %attr(770,root,http) %{_socketdir}/dynamic