]>
Commit | Line | Data |
---|---|---|
eaa174a2 | 1 | # TODO: |
2 | # - split /usr/share/perl* part into perl-ack subpackage | |
7c730201 | 3 | # |
4 | # Conditional build: | |
5 | %bcond_without tests # do not perform "make test" | |
81f268ee | 6 | %bcond_with pty_tests # do not perform tests requiring a pty |
7c730201 | 7 | # |
7c730201 | 8 | %define pdir ack |
9 | Summary: grep-like text finder | |
89a99560 | 10 | Summary(pl.UTF-8): produkt grepopodobny |
33e5a24e | 11 | Name: ack |
fe47564e | 12 | Version: 2.28 |
2e6173ec | 13 | Release: 1 |
7c730201 | 14 | License: GPL v1+ or Artistic |
15 | Group: Development/Languages/Perl | |
81f268ee | 16 | Source0: http://www.cpan.org/modules/by-authors/id/P/PE/PETDANCE/%{name}-%{version}.tar.gz |
fe47564e | 17 | # Source0-md5: 5c363d701cb40cbc3806441b2a887b43 |
7ce2421c | 18 | Patch0: %{name}-deps.patch |
81f268ee | 19 | Patch1: %{name}-interactive-tests.patch |
89a99560 | 20 | URL: http://betterthangrep.com/ |
e6d740cb | 21 | Requires: perl-ack = %{version} |
78a5158c | 22 | %if %{with tests} |
2e6173ec | 23 | BuildRequires: perl-File-Next >= 1.16 |
81f268ee | 24 | %{?with_pty_tests:BuildRequires: perl-IO-Tty} |
78a5158c KK |
25 | BuildRequires: perl-Test-Simple >= 0.98 |
26 | %endif | |
7c730201 | 27 | BuildRequires: perl-devel >= 1:5.8.0 |
28 | BuildRequires: perl-perldoc | |
29 | BuildRequires: rpm-perlprov >= 4.1-13 | |
89a99560 | 30 | BuildArch: noarch |
31 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
32 | ||
33 | %description | |
7c730201 | 34 | Ack is designed as a replacement for 99% of the uses of grep. |
89a99560 | 35 | |
7c730201 | 36 | Ack searches the named input FILEs (or standard input if no files are |
37 | named, or the file name - is given) for lines containing a match to | |
38 | the given PATTERN. By default, ack prints the matching lines. | |
39 | ||
40 | Ack can also list files that would be searched, without actually | |
41 | searching them, to let you take advantage of ack's file-type filtering | |
42 | capabilities. | |
89a99560 | 43 | |
29efeb0a | 44 | %description -l pl.UTF-8 |
3b51bee7 ER |
45 | ack jest narzędziem podobnym do grepa, zaprojektowanym dla |
46 | programistów pracujących z dużymi drzewami różnorodnych plików. | |
89a99560 | 47 | |
561d9e5a TP |
48 | ack jest napisany w czystym perlu i korzysta z potęgi wyrażeń |
49 | regularnych tego języka. | |
89a99560 | 50 | |
33e5a24e | 51 | %package -n perl-ack |
52 | Summary: ack perl library | |
53 | Summary(pl.UTF-8): biblioteka ack dla języka perl | |
54 | Group: Development/Languages/Perl | |
55 | ||
56 | %description -n perl-ack | |
57 | ack perl library. | |
58 | ||
59 | %description -n perl-ack -l pl.UTF-8 | |
60 | ack perl library. | |
61 | ||
89a99560 | 62 | %prep |
7c730201 | 63 | %setup -q -n %{pdir}-%{version} |
7ce2421c | 64 | %patch0 -p0 |
81f268ee | 65 | %patch1 -p0 |
89a99560 | 66 | |
67 | %build | |
7c730201 | 68 | %{__perl} Makefile.PL \ |
69 | INSTALLDIRS=vendor | |
70 | %{__make} \ | |
71 | CC="%{__cc}" \ | |
72 | OPTIMIZE="%{rpmcflags}" | |
73 | ||
81f268ee | 74 | %{?with_tests:%{!?with_pty_tests: RUN_INTERACTIVE=0} %{__make} -j1 test} |
89a99560 | 75 | |
76 | %install | |
77 | rm -rf $RPM_BUILD_ROOT | |
7c730201 | 78 | |
79 | %{__make} pure_install \ | |
80 | DESTDIR=$RPM_BUILD_ROOT | |
89a99560 | 81 | |
82 | %clean | |
83 | rm -rf $RPM_BUILD_ROOT | |
84 | ||
85 | %files | |
86 | %defattr(644,root,root,755) | |
78a5158c | 87 | %doc Changes README.md |
7c730201 | 88 | %attr(755,root,root) %{_bindir}/ack |
33e5a24e | 89 | %{_mandir}/man1/ack.1p* |
90 | ||
91 | %files -n perl-ack | |
92 | %defattr(644,root,root,755) | |
7c730201 | 93 | %{perl_vendorlib}/App/Ack.pm |
94 | %{perl_vendorlib}/App/Ack |