]> git.pld-linux.org Git - packages/apache1-mod_ssl.git/blobdiff - apache1-mod_ssl.spec
- updated to 2.8.25-1.3.34
[packages/apache1-mod_ssl.git] / apache1-mod_ssl.spec
index b3d26eef1b1a7512bb74c551e8ee6e351e9b1e91..85f7aece8f650d431eb25b5af3c236f05e08f432 100644 (file)
@@ -1,7 +1,7 @@
 # TODO
 #  - other language's descriptions look weird, backslashes and quotes
-%define                SSLVER          2.8.22
-%define                APACHEVER       1.3.33
+%define                SSLVER          2.8.25
+%define                APACHEVER       1.3.34
 %define                apxs            /usr/sbin/apxs1
 %define                mod_name        ssl
 Summary:       An SSL module for the Apache Web server
@@ -23,11 +23,11 @@ Summary(sv):        Kryptografist
 Summary(uk):   íÏÄÕÌؠЦÄÔÒÉÍËÉ SSL × Apache
 Name:          apache1-mod_%{mod_name}
 Version:       %{SSLVER}_%{APACHEVER}
-Release:       1.10
+Release:       1
 License:       BSD
 Group:         Networking/Daemons
 Source0:       http://www.modssl.org/source/mod_%{mod_name}-%{SSLVER}-%{APACHEVER}.tar.gz
-# Source0-md5: cdfdf1f576f77768c90825b43b462405
+# Source0-md5: 1ef2a6cb47573444779b2fd10502514b
 Source1:       %{name}.conf
 Source2:       %{name}-server.crt
 Source3:       %{name}-server.key
@@ -45,15 +45,21 @@ BuildRequires:      openssl-devel >= 0.9.7d
 BuildRequires: openssl-tools >= 0.9.7d
 BuildRequires: sed >= 4.0
 Requires(post,preun):  apache1
-Requires(post,preun):  grep
-Requires(preun):       fileutils
+Requires(triggerpostun):       grep
+Requires(triggerpostun):       sed >= 4.0
 Requires:      apache1 >= %{APACHEVER}
-Conflicts:     apache1 < 1.3.33-2
+Requires:      apache1 >= 1.3.33-2
+# see the config
+Requires:      apache1-mod_setenvif
+Requires:      apache1-mod_log_config
+Provides:      apache(mod_ssl) = %{version}-%{release}
+Obsoletes:     apache-mod_ssl < 2
 Obsoletes:     mod_ssl
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
-%define                _pkglibdir      %(%{apxs} -q LIBEXECDIR)
-%define                _sysconfdir     %(%{apxs} -q SYSCONFDIR)
+%define                _pkglibdir      %(%{apxs} -q LIBEXECDIR 2>/dev/null)
+%define                _sysconfdir     %(%{apxs} -q SYSCONFDIR 2>/dev/null)
+%define                _pkglogdir      %(%{apxs} -q PREFIX 2>/dev/null)/logs
 
 %description
 The mod_ssl project provides strong cryptography for the Apache 1.3
@@ -146,8 +152,10 @@ Summary:   Strong Extranet module for mod_ssl and apache
 Summary(fr):   Module d'Extranet Fort pour Apache et mod_ssl
 Summary(pl):   Modu³ Strong Extranet dla pakietu mod_ssl i serwera WWW Apache
 Group:         Networking/Daemons
-Requires(post,preun):  %{apxs}
+Requires(triggerpostun):       %{apxs}
 Requires:      apache1(EAPI) >= %{APACHEVER}
+Requires:      apache1 >= 1.3.33-2
+Obsoletes:     apache-mod_sxnet < 2
 
 %description -n apache1-mod_sxnet
 The Strong Extranet allows you to use digital certificates to
@@ -175,6 +183,9 @@ System.
 
 %{__perl} -pi -e 's@ /lib /usr/lib @ /%{_lib} /usr/%{_lib} @' pkg.sslmod/libssl.module
 
+cd pkg.contrib
+tar xvf sxnet.tar
+
 %build
 SSL_BASE=SYSTEM; export SSL_BASE
 %configure \
@@ -184,14 +195,12 @@ SSL_BASE=SYSTEM; export SSL_BASE
 
 %{__make}
 
-cd pkg.contrib
-tar xvf sxnet.tar
-cd sxnet
+cd pkg.contrib/sxnet
 %{apxs} -DMalloc=malloc -DFree=free -I%{_includedir}/openssl -L%{_libdir} -l ssl -l crypto -c mod_sxnet.c
 
 %install
 rm -rf $RPM_BUILD_ROOT
-install -d $RPM_BUILD_ROOT{%{_libdir}/mod_%{mod_name},%{_pkglibdir}} \
+install -d $RPM_BUILD_ROOT{%{_libdir}/mod_%{mod_name},%{_pkglibdir},%{_pkglogdir}} \
        $RPM_BUILD_ROOT%{_includedir}/apache1 \
        $RPM_BUILD_ROOT%{_sysconfdir}/conf.d \
        $RPM_BUILD_ROOT/etc/logrotate.d
@@ -208,11 +217,14 @@ install %{SOURCE5} $RPM_BUILD_ROOT/etc/logrotate.d/apache-mod_%{mod_name}
 cp -a pkg.ssldoc ssl-doc
 
 install %{SOURCE4} sxnet.html
-CFG="$RPM_BUILD_ROOT%{_sysconfdir}/conf.d"
-echo "LoadModule sxnet_module  modules/mod_sxnet.so" > $CFG/41_mod_sxnet.conf
+echo 'LoadModule sxnet_module  modules/mod_sxnet.so' > \
+       $RPM_BUILD_ROOT%{_sysconfdir}/conf.d/90_mod_sxnet.conf
 
 install pkg.sslmod/*.h $RPM_BUILD_ROOT%{_includedir}/apache1
 
+> $RPM_BUILD_ROOT%{_pkglogdir}/ssl_engine_log
+> $RPM_BUILD_ROOT%{_pkglogdir}/ssl_request_log
+
 %clean
 rm -rf $RPM_BUILD_ROOT
 
@@ -223,7 +235,7 @@ else
        echo "Run \"/etc/rc.d/init.d/apache start\" to start apache HTTP daemon."
 fi
 
-%preun
+%postun
 if [ "$1" = "0" ]; then
        if [ -f /var/lock/subsys/apache ]; then
                /etc/rc.d/init.d/apache restart 1>&2
@@ -231,7 +243,7 @@ if [ "$1" = "0" ]; then
 fi
 
 %triggerpostun -- apache1-mod_ssl < 2.8.22_1.3.33-1.7
-if grep -q '^Include conf.d' /etc/apache/apache.conf; then
+if grep -q '^Include conf\.d/\*\.conf' /etc/apache/apache.conf; then
        sed -i -e '
                /^Include.*mod_%{mod_name}.conf/d
        ' /etc/apache/apache.conf
@@ -244,7 +256,7 @@ fi
 
 %triggerpostun -- apache1-mod_sxnet < 2.8.22_1.3.33-1.9
 # check that they're not using old apache.conf
-if ! grep -q '^Include conf.d' /etc/apache/apache.conf; then
+if grep -q '^Include conf\.d' /etc/apache/apache.conf; then
        %{apxs} -e -A -n sxnet %{_pkglibdir}/mod_sxnet.so 1>&2
 fi
 
@@ -253,7 +265,7 @@ if [ -f /var/lock/subsys/apache ]; then
        /etc/rc.d/init.d/apache restart 1>&2
 fi
 
-%preun -n apache1-mod_sxnet
+%postun -n apache1-mod_sxnet
 if [ "$1" = "0" ]; then
        if [ -f /var/lock/subsys/apache ]; then
                /etc/rc.d/init.d/apache restart 1>&2
@@ -263,10 +275,11 @@ fi
 %files
 %defattr(644,root,root,755)
 %doc ANNOUNCE CHANGES CREDITS NEWS README* ssl-doc
-%attr(640,root,root) %config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/conf.d/*_mod_ssl.conf
-%attr(640,root,root) %config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/server.crt
-%attr(640,root,root) %config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/server.key
-%attr(640,root,root) %config(noreplace) %verify(not size mtime md5) /etc/logrotate.d/*
+%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/conf.d/*_mod_ssl.conf
+%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/server.crt
+%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/server.key
+%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/logrotate.d/*
+%attr(640,root,root) %ghost %{_pkglogdir}/*
 
 %attr(755,root,root) %{_pkglibdir}/libssl.so
 
@@ -280,5 +293,5 @@ fi
 %files -n apache1-mod_sxnet
 %defattr(644,root,root,755)
 %doc sxnet.html
-%attr(640,root,root) %config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/conf.d/*_mod_sxnet.conf
+%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/conf.d/*_mod_sxnet.conf
 %attr(755,root,root) %{_pkglibdir}/mod_sxnet.so
This page took 0.076367 seconds and 4 git commands to generate.