]> git.pld-linux.org Git - packages/apache1-mod_frontpage.git/blobdiff - apache1-mod_frontpage.spec
- adapterized (sorted %verify attrs)
[packages/apache1-mod_frontpage.git] / apache1-mod_frontpage.spec
index 4bd18ce89f1656b9c7d379b4d7af81286d882c03..eb1d3b35b58ba3ab43095f5b3f946638355cc0ad 100644 (file)
@@ -4,7 +4,7 @@ Summary:        The improved mod_frontpage module for the Apache Web server
 Summary(pl):   Ulepszony modu³ mod_frontpage dla serwera Apache
 Name:          apache1-mod_%{mod_name}
 Version:       1.6.2
 Summary(pl):   Ulepszony modu³ mod_frontpage dla serwera Apache
 Name:          apache1-mod_%{mod_name}
 Version:       1.6.2
-Release:       1
+Release:       2
 License:       Apache
 Group:         Networking/Daemons
 Source0:       http://dl.sourceforge.net/mirfak/mod_%{mod_name}_mirfak-%{version}.tar.bz2
 License:       Apache
 Group:         Networking/Daemons
 Source0:       http://dl.sourceforge.net/mirfak/mod_%{mod_name}_mirfak-%{version}.tar.bz2
@@ -12,22 +12,21 @@ Source0:    http://dl.sourceforge.net/mirfak/mod_%{mod_name}_mirfak-%{version}.tar.
 Source1:       %{name}.pl
 Patch0:                %{name}-mirfak.patch
 URL:           http://mirfak.sourceforge.net/
 Source1:       %{name}.pl
 Patch0:                %{name}-mirfak.patch
 URL:           http://mirfak.sourceforge.net/
-BuildRequires: apache1-devel >= 1.3.23
 BuildRequires: %{__perl}
 BuildRequires: %{__perl}
-PreReq:                apache1 >= 1.3.23
-Requires(post,preun):  %{apxs}
-Requires:      apache1
+BuildRequires: apache1-devel >= 1.3.33-2
+Requires(triggerpostun):       %{apxs}
+Requires:              apache1 >= 1.3.33-2
 Obsoletes:     apache-mod_%{mod_name} <= %{version}
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
 Obsoletes:     apache-mod_%{mod_name} <= %{version}
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
-%define                _pkglibdir      %(%{apxs} -q LIBEXECDIR)
-%define                _sysconfdir     /etc/apache
+%define                _pkglibdir      %(%{apxs} -q LIBEXECDIR 2>/dev/null)
+%define                _sysconfdir     %(%{apxs} -q SYSCONFDIR 2>/dev/null)
 
 %description
 This is a module for the Apache HTTP Server
 
 %description
 This is a module for the Apache HTTP Server
-<http://www.apache.org/httpd.html>. It replaces the Apache-FP patches
-and module supplied with the FrontPage Server Extensions available
-from Microsoft <http://www.microsoft.com/> and Ready-to-Run Software
+<http://httpd.apache.org/>. It replaces the Apache-FP patches and
+module supplied with the FrontPage Server Extensions available from
+Microsoft <http://www.microsoft.com/> and Ready-to-Run Software
 <http://www.rtr.com/fpsupport/>.
 
 Using this module allows you to use advanced features of the FrontPage
 <http://www.rtr.com/fpsupport/>.
 
 Using this module allows you to use advanced features of the FrontPage
@@ -56,31 +55,39 @@ uruchamiania fpinstall.sh lub fpsrvadm.exe z pow
 
 %install
 rm -rf $RPM_BUILD_ROOT
 
 %install
 rm -rf $RPM_BUILD_ROOT
-install -d $RPM_BUILD_ROOT{%{_pkglibdir},%{_sbindir}}
+install -d $RPM_BUILD_ROOT{%{_pkglibdir},%{_sysconfdir}/conf.d,%{_sbindir}}
 
 install mod_%{mod_name}.so $RPM_BUILD_ROOT%{_pkglibdir}
 install fp{exec,static} $RPM_BUILD_ROOT%{_sbindir}
 
 
 install mod_%{mod_name}.so $RPM_BUILD_ROOT%{_pkglibdir}
 install fp{exec,static} $RPM_BUILD_ROOT%{_sbindir}
 
+echo 'LoadModule %{mod_name}_module    modules/mod_%{mod_name}.so' > \
+       $RPM_BUILD_ROOT%{_sysconfdir}/conf.d/90_mod_%{mod_name}.conf
+
 %clean
 rm -rf $RPM_BUILD_ROOT
 
 %post
 %clean
 rm -rf $RPM_BUILD_ROOT
 
 %post
-%{apxs} -e -a -n %{mod_name} %{_pkglibdir}/mod_%{mod_name}.so 1>&2
 if [ -f /var/lock/subsys/apache ]; then
        /etc/rc.d/init.d/apache restart 1>&2
 fi
 
 if [ -f /var/lock/subsys/apache ]; then
        /etc/rc.d/init.d/apache restart 1>&2
 fi
 
-%preun
+%postun
 if [ "$1" = "0" ]; then
 if [ "$1" = "0" ]; then
-       %{apxs} -e -A -n %{mod_name} %{_pkglibdir}/mod_%{mod_name}.so 1>&2
        if [ -f /var/lock/subsys/apache ]; then
                /etc/rc.d/init.d/apache restart 1>&2
        fi
 fi
 
        if [ -f /var/lock/subsys/apache ]; then
                /etc/rc.d/init.d/apache restart 1>&2
        fi
 fi
 
+%triggerpostun -- apache1-mod_%{mod_name} < 1.6.2-1.1
+# check that they're not using old apache.conf
+if grep -q '^Include conf\.d' /etc/apache/apache.conf; then
+       %{apxs} -e -A -n %{mod_name} %{_pkglibdir}/mod_%{mod_name}.so 1>&2
+fi
+
 %files
 %defattr(644,root,root,755)
 %doc *.html CHANGES FEATURES README
 %files
 %defattr(644,root,root,755)
 %doc *.html CHANGES FEATURES README
+%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/conf.d/*_mod_%{mod_name}.conf
 %attr(755,root,root) %{_pkglibdir}/*
 %attr(4750,root,root) %{_sbindir}/fpexec
 %attr(755,root,root) %{_sbindir}/fpstatic
 %attr(755,root,root) %{_pkglibdir}/*
 %attr(4750,root,root) %{_sbindir}/fpexec
 %attr(755,root,root) %{_sbindir}/fpstatic
This page took 0.075696 seconds and 4 git commands to generate.