3 %bcond_without tests # do not perform "make test"
5 %include /usr/lib/rpm/macros.perl
7 %define pnam RecDescent
8 Summary: Parse::RecDescent - generate recursive-descent parsers
9 Summary(pl.UTF-8): Parse::RecDescent - generowanie zmniejszających rekurencyjnie analizatorów
10 Name: perl-Parse-RecDescent
14 Group: Development/Languages/Perl
15 Source0: http://www.cpan.org/modules/by-module/Parse/%{pdir}-%{pnam}-%{version}.tar.gz
16 # Source0-md5: 98f582240556a4a92e5d57e480f9d39d
17 URL: http://search.cpan.org/dist/Parse-RecDescent/
18 BuildRequires: perl-Text-Balanced
19 BuildRequires: perl-devel >= 1:5.8.0
20 BuildRequires: rpm-perlprov >= 4.1-13
21 # these versions included own copy of Text::Balanced
22 BuildConflicts: perl-Parse-RecDescent < 1.92
24 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
26 %define _noautoreq 'perl(Calc)'
29 RecDescent incrementally generates top-down recursive-descent text
30 parsers from simple yacc-like grammar specifications. It provides:
31 - Regular expressions or literal strings as terminals (tokens),
32 - Multiple (non-contiguous) productions for any rule,
33 - Repeated, optional and alternate subrules within productions,
34 - Late-bound (run-time dispatched) subrules,
35 - Full access to Perl within actions specified as part of the grammar,
36 - Simple automated error reporting during parser generation and
38 - The ability to commit to, uncommit to, or reject particular
39 productions during a parse,
40 - Incremental extension of the parsing grammar (even during a parse),
41 - Precompilation of parser objects,
42 - User-definable reduce-reduce conflict resolution via "scoring" of
45 %description -l pl.UTF-8
46 RecDescent generuje przyrostowo zstępujące, zmniejszające
47 rekurencyjnie analizatory tekstu w oparciu o prostą specyfikację
48 gramatyki, podobną do używanej przez yacca. Udostępnia on:
49 - Wyrażenia regularne i łańcuchy literałów jako terminale (tokeny),
50 - Wielokrotną (nieciągłą) produkcję dla każdej reguły,
51 - Powtarzane, opcjonalne i alternatywne podreguły w obrębie produkcji,
52 - Podreguły późnego wiązania (wysyłane w chwili uruchomienia),
53 - Pełen dostęp do Perla w obrębie akcji określonych jako część
55 - Proste, zautomatyzowane sygnalizowanie błędów podczas generacji
56 analizatora i podczas analizy,
57 - Możliwość zatwierdzenia, cofnięcia oraz odrzucania poszczególnych
58 produkcji podczas analizy,
59 - Przyrostowe rozszerzanie gramatyki podlegającej analizie (nawet
60 podczas samej analizy),
61 - Prekompilację obiektów analizatora,
62 - Definiowalne przez użytkownika rozpoznawanie konfliktów
63 "reduce-reduce" poprzez ocenianie dopasowania produkcji.
66 %setup -q -n %{pdir}-%{pnam}-%{version}
69 %{__perl} Makefile.PL \
73 %{?with_tests:%{__make} test}
76 rm -rf $RPM_BUILD_ROOT
78 %{__make} pure_install \
79 DESTDIR=$RPM_BUILD_ROOT
81 %{__rm} $RPM_BUILD_ROOT%{perl_vendorarch}/auto/Parse/RecDescent/.packlist
84 rm -rf $RPM_BUILD_ROOT
87 %defattr(644,root,root,755)
89 %{perl_vendorlib}/Parse/RecDescent.pm
90 %{_mandir}/man3/Parse::RecDescent.3pm*