2 # - tests are disabled as one is broken: https://github.com/book/HTTP-Proxy/issues/7
5 %bcond_without autodeps # don't BR packages needed only for resolving deps
6 %bcond_with tests # do not perform "make test"
10 Summary: A pure Perl HTTP proxy
11 Summary(pl.UTF-8): Proxy HTTP zaimplementowany w czystym Perlu
12 Name: perl-%{pdir}-%{pnam}
16 License: GPL v1+ or Artistic
17 Group: Development/Languages/Perl
18 Source0: http://www.cpan.org/modules/by-module/%{pdir}/%{pdir}-%{pnam}-%{version}.tar.gz
19 # Source0-md5: 09ac64c5f67b7d8baff4ea135d74af48
20 URL: http://search.cpan.org/dist/HTTP-Proxy/
21 BuildRequires: perl-devel >= 1:5.8.0
22 BuildRequires: rpm-perlprov >= 4.1-13
23 %if %{with autodeps} || %{with tests}
24 BuildRequires: perl(HTTP::Daemon) >= 1.25
25 BuildRequires: perl(LWP::UserAgent) >= 2
26 BuildRequires: perl-libwww >= 1.25
29 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
32 This module implements a HTTP proxy, using a HTTP::Daemon to accept
33 client connections, and a LWP::UserAgent to ask for the requested
36 The most interesting feature of this proxy object is its ability to
37 filter the HTTP requests and responses through user-defined filters.
39 %description -l pl.UTF-8
40 Ten moduł implementuje proxy HTTP, używając HTTP::Daemon do
41 przyjmowania połączeń klienckich i LWP::UserAgent do pobierania
44 Najciekawszą opcją tego obiektu proxy jest możliwość filtrowania
45 zapytań i odpowiedzi HTTP poprzez filtry definiowane przez
49 %setup -q -n %{pdir}-%{pnam}-%{version}
52 %{__perl} Makefile.PL \
56 %{?with_tests:%{__make} test}
59 rm -rf $RPM_BUILD_ROOT
60 %{__make} pure_install \
61 DESTDIR=$RPM_BUILD_ROOT
63 install -d $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
64 cp -a eg/* $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
67 rm -rf $RPM_BUILD_ROOT
70 %defattr(644,root,root,755)
72 %{perl_vendorlib}/HTTP/Proxy.pm
73 %{perl_vendorlib}/HTTP/Proxy
75 %{_examplesdir}/%{name}-%{version}