]> git.pld-linux.org Git - packages/perl-Capture-Tiny.git/blame - perl-Capture-Tiny.spec
up to 0.27
[packages/perl-Capture-Tiny.git] / perl-Capture-Tiny.spec
CommitLineData
6dcdf440
JR
1#
2# Conditional build:
3%bcond_without tests # do not perform "make test"
bce3154a 4
6dcdf440
JR
5%define pdir Capture
6%define pnam Tiny
7%include /usr/lib/rpm/macros.perl
8Summary: Capture::Tiny - Capture STDOUT and STDERR from Perl, XS or external programs
6131258a 9Summary(pl.UTF-8): Capture::Tiny - przechwytywanie STDOUT i STDERR z Perla, XS lub programów zewnętrznych
6dcdf440 10Name: perl-Capture-Tiny
bce3154a 11Version: 0.27
6243c41b 12Release: 1
6131258a 13License: Apache v2.0
6dcdf440
JR
14Group: Development/Languages/Perl
15Source0: http://www.cpan.org/modules/by-authors/id/D/DA/DAGOLDEN/Capture-Tiny-%{version}.tar.gz
bce3154a 16# Source0-md5: 63ee233f1dfaa75c5233839407b87ae3
6131258a
JB
17URL: http://search.cpan.org/dist/Capture-Tiny/
18BuildRequires: perl-ExtUtils-MakeMaker >= 6.30
6dcdf440
JR
19BuildRequires: perl-devel >= 1:5.8.0
20BuildRequires: rpm-perlprov >= 4.1-13
21%if %{with tests}
6131258a
JB
22BuildRequires: perl-Inline
23BuildRequires: perl-Inline-C
24BuildRequires: perl-Test-Simple
6dcdf440
JR
25%endif
26BuildArch: noarch
27BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
28
29%description
30Capture::Tiny provides a simple, portable way to capture anything sent
31to STDOUT or STDERR, regardless of whether it comes from Perl, from XS
32code or from an external program. Optionally, output can be teed so
33that it is captured while being passed through to the original
34handles. Yes, it even works on Windows. Stop guessing which of a dozen
35capturing modules to use in any particular situation and just use this
36one.
37
38This module was heavily inspired by IO::CaptureOutput, which provides
39similar functionality without the ability to tee output and with more
40complicated code and API.
41
6131258a
JB
42%description -l pl.UTF-8
43Capture::Tiny dostarcza prosty, przenośny sposób przechwytywania
44wszystkiego, co zostało przesłane na STDOUT lub STDERR, niezależnie od
45tego, czy pochodzi z Perla, kodu XS lub programu zewnętrznego.
46Opcjonalnie może działać jak tee, podczas przechwytywania przekazując
47dane do oryginalnych uchwytów. Moduł działa nawet pod Windows. Nie
48trzeba zgadywać, który z modułów przechwytujących działa w danej
49sytuacji.
50
51Ten moduł był w dużym stopniu inspirowany modułem IO::CaptureOutput,
52który zapewnia podobną funkcjonalność bez możliwości przekazywania
53wyjścia jak tee i ma nieco bardziej złożone API.
6dcdf440
JR
54
55%prep
56%setup -q -n %{pdir}-%{pnam}-%{version}
57
58%build
59%{__perl} Makefile.PL \
60 INSTALLDIRS=vendor
61%{__make}
62
63%{?with_tests:%{__make} test}
64
65%install
66rm -rf $RPM_BUILD_ROOT
67
68%{__make} pure_install \
69 DESTDIR=$RPM_BUILD_ROOT
70
6131258a 71install -d $RPM_BUILD_ROOT%{_examplesdir}
6dcdf440
JR
72cp -a examples $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
73
74%clean
75rm -rf $RPM_BUILD_ROOT
76
77%files
78%defattr(644,root,root,755)
6131258a 79%doc Changes README Todo
cde95a1f 80%dir %{perl_vendorlib}/Capture
6131258a
JB
81%{perl_vendorlib}/Capture/Tiny.pm
82%{_mandir}/man3/Capture::Tiny.3pm*
6dcdf440 83%{_examplesdir}/%{name}-%{version}
This page took 0.096715 seconds and 4 git commands to generate.