]> git.pld-linux.org Git - packages/apache-mod_fastcgi.git/blobdiff - apache-mod_fastcgi.spec
- use %service
[packages/apache-mod_fastcgi.git] / apache-mod_fastcgi.spec
index 70f8f73cf96d9f91f84ee5916d926e25122662ea..cea8282b83818b74b3561933e0bc9358314e59be 100644 (file)
@@ -1,16 +1,33 @@
+%define                mod_name        fastcgi
+%define        apxs            /usr/sbin/apxs
 Summary:       Support for the FastCGI protocol for apache webserver
 Summary:       Support for the FastCGI protocol for apache webserver
-Name:          apache-mod_fastcgi
-Version:       2.2.8
-Release:       2
-Copyright:     Open Market
+Summary(pl):   Obs³uga protoko³u FastCGI dla serwera apache
+Summary(ru):   FastCGI - ÂÏÌÅÅ ÂÙÓÔÒÁÑ ×ÅÒÓÉÑ CGI
+Summary(uk):   FastCGI - Â¦ÌØÛ Û×ÉÄËÁ ×ÅÒӦѠCGI
+Name:          apache-mod_%{mod_name}
+# NOTE: remember about apache1-mod_fastcgi.spec when messing here
+Version:       2.4.2
+Release:       8
+License:       distributable
 Group:         Networking/Daemons
 Group:         Networking/Daemons
-Group(de):     Netzwerkwesen/Server
-Group(pl):     Sieciowe/Serwery
+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
+Patch3:                %{name}-apache22.patch
+Source1:       %{name}.conf
 URL:           http://www.FastCGI.com/
 URL:           http://www.FastCGI.com/
-Source0:       http://www.FastCGI.com/dist/mod_fastcgi_%{version}.tar.gz
-Requires:      apache >= 1.3.1
+BuildRequires: %{apxs}
+BuildRequires: apache-devel >= 2.2
+BuildRequires: libtool
+BuildRequires: rpmbuild(macros) >= 1.268
+Requires:      apache(modules-api) = %apache_modules_api
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
-BuildRequires: apache-devel
+
+%define                _pkglibdir      %(%{apxs} -q LIBEXECDIR 2>/dev/null)
+%define                _sysconfdir     %(%{apxs} -q SYSCONFDIR 2>/dev/null)
+%define                _socketdir      /var/run/httpd/fastcgi
 
 %description
 This 3rd party module provides support for the FastCGI protocol.
 
 %description
 This 3rd party module provides support for the FastCGI protocol.
@@ -18,49 +35,60 @@ FastCGI is a language independent, scalable, open extension to CGI
 that provides high performance and persistence without the limitations
 of server specific APIs.
 
 that provides high performance and persistence without the limitations
 of server specific APIs.
 
-%define         _libexecdir     /usr/lib/apache
-%define         _htmldocdir     /home/httpd/html/docs/%{name}_%{version}
+%description -l pl
+To jest modu³ apache dodaj±cy obs³ugê protoko³u FastCGI. FastCGI jest
+niezale¿nym od jêzyka, skalowalnym, otwartym rozszerzeniem CGI daj±cym
+du¿± wydajno¶æ bez ograniczania API specyficznego dla serwera.
+
+%description -l ru
+FastCGI - ÒÁÓÛÉÒÅÎÉÅ CGI, ËÏÔÏÒÏÅ ÐÒÅÄÏÓÔÁ×ÌÑÅÔ ×ÏÚÍÏÖÎÏÓÔØ ÓÏÚÄÁ×ÁÔØ
+×ÙÓÏËÏÐÒÏÉÚ×ÏÄÉÔÅÌØÎÙÅ Internet-ÐÒÉÌÏÖÅÎÉÑ ÂÅÚ ÎÅÏÂÈÏÄÉÍÏÓÔÉ
+ÉÓÐÏÌØÚÏ×ÁÔØ ÓÐÅÃÉÆÉÞÅÓËÉÅ ÄÌÑ ËÁÖÄÏÇÏ web-ÓÅÒ×ÅÒÁ API.
+
+óËÏÒÏÓÔØ API web-ÓÅÒ×ÅÒÏ× ÓÏ ×ÓÅÍÉ ÐÒÅÉÍÕÝÅÓÔ×ÁÍÉ CGI.
+
+%description -l uk
+FastCGI - ÒÏÚÛÉÒÅÎÎÑ CGI, ÑËÅ ÎÁÄÁ¤ ÍÏÖÌÉצÓÔØ ÓÔ×ÏÒÀ×ÁÔÉ
+×ÉÓÏËÏÐÒÏÄÕËÔÉ×Φ Internet-ÐÒÏÇÒÁÍÉ ÂÅÚ ÎÅÏÂȦÄÎÏÓÔ¦ ×ÉËÏÒÉÓÔÁÎÎÑ
+ÓÐÅÃÉƦÞÎÉÈ ÄÌÑ ËÏÖÎÏÇÏ web-ÓÅÒ×ÅÒÕ API.
+
+û×ÉÄ˦ÓÔØ API web-ÓÅÒ×ÅҦנڦ ×Ó¦ÍÁ ÐÅÒÅ×ÁÇÁÍÉ CGI.
 
 %prep
 
 %prep
-%setup -q -n mod_fastcgi_%{version}
+%setup -q -n mod_%{mod_name}-%{version}
+%patch0 -p1
+%patch1 -p1
+%patch2 -p1
+%patch3 -p1
 
 %build
 
 %build
-apxs -D SUEXEC_BIN="/usr/sbin/suexec" -o mod_fastcgi.so -c *.c
-strip mod_fastcgi.so
+%{__make} -f Makefile.AP2 \
+       top_dir=%{_pkglibdir} \
+       INCLUDES="-I%(%{apxs} -q INCLUDEDIR)" \
+       EXTRA_CFLAGS='-DAPACHE22'
 
 %install
 rm -rf $RPM_BUILD_ROOT
 
 %install
 rm -rf $RPM_BUILD_ROOT
-install -d $RPM_BUILD_ROOT{%{_libexecdir},%{_htmldocdir}}
-
-install mod_fastcgi.so $RPM_BUILD_ROOT%{_libexecdir}
-
-install docs/*.html $RPM_BUILD_ROOT%{_htmldocdir}
+install -d $RPM_BUILD_ROOT{%{_pkglibdir},%{_sysconfdir}/httpd.conf,%{_socketdir}/dynamic}
 
 
-gzip -9nf docs/LICENSE.TERMS CHANGES
+install .libs/mod_%{mod_name}.so $RPM_BUILD_ROOT%{_pkglibdir}
+install %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/httpd.conf/90_mod_%{mod_name}.conf
 
 
-strip --strip-unneeded $RPM_BUILD_ROOT%{_libexecdir}/*
+%clean
+rm -rf $RPM_BUILD_ROOT
 
 %post
 
 %post
-%{_sbindir}/apxs -e -a -n fastcgi %{_libexecdir}/mod_fastcgi.so 1>&2
-if [ -f /var/lock/subsys/httpd ]; then
-       /etc/rc.d/init.d/httpd restart 1>&2
-else
-       echo "Run \"/etc/rc.d/init.d/httpd start\" to start apache http daemon."
-fi
+%service -q httpd restart
 
 %preun
 if [ "$1" = "0" ]; then
 
 %preun
 if [ "$1" = "0" ]; then
-       %{_sbindir}/apxs -e -A -n fastcgi %{_libexecdir}/mod_fastcgi.so 1>&2
-       if [ -f /var/lock/subsys/httpd ]; then
-               /etc/rc.d/init.d/httpd restart 1>&2
-       fi
+       %service -q httpd restart
 fi
 
 fi
 
-%clean
-rm -rf $RPM_BUILD_ROOT
-
 %files
 %defattr(644,root,root,755)
 %files
 %defattr(644,root,root,755)
-%doc docs/*.gz CHANGES.gz
-%doc %{_htmldocdir}
-%attr(755,root,root) %{_libexecdir}/*
+%doc docs/LICENSE.TERMS CHANGES docs/*.html
+%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/httpd.conf/*_mod_%{mod_name}.conf
+%attr(755,root,root) %{_pkglibdir}/*.so
+%dir %attr(770,root,http) %{_socketdir}
+%dir %attr(770,root,http) %{_socketdir}/dynamic
This page took 0.317286 seconds and 4 git commands to generate.