3 %bcond_without tests # do not perform "make test"
6 %define pnam FormatExternal
7 Summary: HTML::FormatExternal - HTML to text formatting using external programs
8 Summary(pl.UTF-8): HTML::FormatExternal - formatowanie HTML-a do tekstu przy użyciu programów zewnętrznych
9 Name: perl-HTML-FormatExternal
13 Group: Development/Languages/Perl
14 Source0: http://www.cpan.org/modules/by-module/HTML/%{pdir}-%{pnam}-%{version}.tar.gz
15 # Source0-md5: 94ad331e344440306cd821b0260ddb4f
16 URL: http://search.cpan.org/dist/HTML-FormatExternal/
17 BuildRequires: perl-devel >= 1:5.8.0
18 BuildRequires: rpm-perlprov >= 4.1-13
20 BuildRequires: perl-IPC-Run
21 BuildRequires: perl-URI >= 0.08
22 BuildRequires: perl-constant-defer
25 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
28 This is a collection of formatter modules turning HTML into plain text
29 by dumping it through the respective external programs.
31 HTML::FormatText::Elinks HTML::FormatText::Html2text
32 HTML::FormatText::Links HTML::FormatText::Lynx
33 HTML::FormatText::Netrik HTML::FormatText::Vilistextum
34 HTML::FormatText::W3m HTML::FormatText::Zen
36 The module interfaces are compatible with HTML::Formatter modules such
37 as HTML::FormatText, but the external programs do all the work.
39 Common formatting options are used where possible, such as leftmargin
40 and rightmargin. So just by switching the class you can use a
41 different program (or the plain HTML::FormatText) according to
42 personal preference, or strengths and weaknesses, or what you've got.
44 There's nothing particularly difficult about piping through these
45 programs, but a unified interface hides details like how to set
46 margins and how to force input or output charsets.
48 %description -l pl.UTF-8
49 Ten pakiet zawiera zbiór modułów formatujących zamieniających HTML na
50 zwykły tekst poprzez zrzucanie go przez odpowiednie programy
53 HTML::FormatText::Elinks HTML::FormatText::Html2text
54 HTML::FormatText::Links HTML::FormatText::Lynx
55 HTML::FormatText::Netrik HTML::FormatText::Vilistextum
56 HTML::FormatText::W3m HTML::FormatText::Zen
58 Interfejsy modułów są zgodne z modułami HTML::Formatter, takimi jak
59 HTML::FormatText, ale cała praca wykonywana jest przez zewnętrzne
62 W miarę możliwości używane są wspólne opcje formatowania, takie jak
63 marginesy (leftmargin i rightmargin). Poprzez proste przełączenie
64 klasy można używać innego programu (lub zwykłego HTML::FormatText)
65 według własnych preferencji, zalet i wad, albo posiadanych programów.
67 Nie ma nic trudnego w przepuszczaniu potoków przez te programy, ale
68 ujednolicony interfejs ukrywa szczegóły, takie jak sposób ustawiania
69 marginesów, albo wymuszania wejściowego lub wyjściowego zestawu
73 %setup -q -n %{pdir}-%{pnam}-%{version}
76 %{__perl} Makefile.PL \
80 %{?with_tests:%{__make} test}
83 rm -rf $RPM_BUILD_ROOT
85 %{__make} pure_install \
86 DESTDIR=$RPM_BUILD_ROOT
88 install -d $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
89 cp -a examples $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
92 rm -rf $RPM_BUILD_ROOT
95 %defattr(644,root,root,755)
97 %{perl_vendorlib}/HTML/FormatExternal.pm
98 # XXX: shared with perl-HTML-FormatText-WithLinks
99 %dir %{perl_vendorlib}/HTML/FormatText
100 %{perl_vendorlib}/HTML/FormatText/Elinks.pm
101 %{perl_vendorlib}/HTML/FormatText/Html2text.pm
102 %{perl_vendorlib}/HTML/FormatText/Links.pm
103 %{perl_vendorlib}/HTML/FormatText/Lynx.pm
104 %{perl_vendorlib}/HTML/FormatText/Netrik.pm
105 %{perl_vendorlib}/HTML/FormatText/Vilistextum.pm
106 %{perl_vendorlib}/HTML/FormatText/W3m.pm
107 %{perl_vendorlib}/HTML/FormatText/Zen.pm
108 %{_mandir}/man3/HTML::FormatExternal.3pm*
109 %{_mandir}/man3/HTML::FormatText::*.3pm*
110 %{_examplesdir}/%{name}-%{version}