]> git.pld-linux.org Git - packages/apache1-mod_rpaf.git/blobdiff - apache1-mod_rpaf.spec
- define ServerName -- apache: cannot determine local host name.
[packages/apache1-mod_rpaf.git] / apache1-mod_rpaf.spec
index f461943467b66265123187c2284efe5721bf5056..bd57c84514bce480d74954e1dc8bae1f09f33174 100644 (file)
@@ -1,31 +1,43 @@
 #
 # Conditional build:
 %bcond_without ipv6            # disable IPv6 support
-#
+%bcond_without tests   # do not perform "make test"
+
 %define                mod_name        rpaf
 %define        apxs            %{_sbindir}/apxs1
 Summary:       Reverse proxy add forward module for Apache
 Summary(pl.UTF-8):     Moduł Apache'a dodający przekazywanie dla odwrotnych proxy
 Name:          apache1-mod_%{mod_name}
-Version:       0.5
-Release:       9
+Version:       0.6
+Release:       2
 License:       Apache
 Group:         Networking/Daemons
-Source0:       http://stderr.net/apache/rpaf/download/mod_%{mod_name}-%{version}.tar.gz
-# Source0-md5: 471fb059d6223a394f319b7c8ab45c4d
+Source0:       http://stderr.net/apache/rpaf/download/mod_rpaf-%{version}.tar.gz
+# Source0-md5: ba2b89274e1dd4c0f96f8d034fa305b1
 Source1:       %{name}.conf
-Patch0:                %{name}-ipv6.patch
-Patch1:                mod_rpaf_degtine.patch
-Patch2:                %{name}_degtine.patch
+Patch0:                mod_rpaf_degtine.patch
+Patch1:                tests.patch
 URL:           http://stderr.net/apache/rpaf/
-%{?with_ipv6:BuildRequires:    apache1(ipv6)-devel}
 BuildRequires: apache1-devel >= 1.3.39
 BuildRequires: rpmbuild(macros) >= 1.268
-%{!?with_ipv6:BuildConflicts:  apache1(ipv6)-devel}
 Requires:      apache1(EAPI)
-%{?with_ipv6:Requires: apache1(ipv6)}
 Provides:      apache(mod_rpaf)
-%{!?with_ipv6:Conflicts:       apache1(ipv6)}
+%if %{with ipv6}
+BuildRequires: apache1(ipv6)-devel
+Requires:      apache1(ipv6)
+%else
+BuildConflicts:        apache1(ipv6)-devel
+Conflicts:     apache1(ipv6)
+%endif
+%if %{with tests}
+BuildRequires: apache1-base
+BuildRequires: apache1-mod_alias
+BuildRequires: apache1-mod_cgi
+BuildRequires: apache1-mod_log_config
+BuildRequires: apache1-mod_mime
+BuildRequires: apache1-mod_rewrite
+BuildRequires: perl-libwww
+%endif
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
 %define                _pkglibdir      %(%{apxs} -q LIBEXECDIR 2>/dev/null)
@@ -51,23 +63,25 @@ Bjoerna Hansena. Będzie także działać z mod_proxy w Apache'u począwszy
 od wersji 1.3.25.
 
 %prep
-%setup -q -n mod_%{mod_name}-%{version}
-%if %{with ipv6}
+%setup -qc
+mv mod_%{mod_name}-%{version}/* .
 %patch0 -p1
-%patch2 -p1
-%else
 %patch1 -p1
-%endif
 
 %build
 %{apxs} -c mod_%{mod_name}.c -o mod_%{mod_name}.so
 
+%if %{with tests}
+ln -sf %{_libdir}/apache1 modules
+%{__make} test
+%endif
+
 %install
 rm -rf $RPM_BUILD_ROOT
 install -d $RPM_BUILD_ROOT{%{_pkglibdir},%{_sysconfdir}/conf.d}
 
-install mod_%{mod_name}.so $RPM_BUILD_ROOT%{_pkglibdir}
-install %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/conf.d/99_mod_%{mod_name}.conf
+install -p mod_%{mod_name}.so $RPM_BUILD_ROOT%{_pkglibdir}
+cp -p %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/conf.d/99_mod_%{mod_name}.conf
 
 %clean
 rm -rf $RPM_BUILD_ROOT
@@ -82,6 +96,6 @@ fi
 
 %files
 %defattr(644,root,root,755)
-%doc README CHANGES test.pl
+%doc README CHANGES
 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/conf.d/*_mod_%{mod_name}.conf
 %attr(755,root,root) %{_pkglibdir}/*
This page took 0.179418 seconds and 4 git commands to generate.