1 %include /usr/lib/rpm/macros.perl
4 Summary: Tree::Trie - An implementation of the Trie data structure in Perl
5 Summary(pl): Tree::Trie - perlowa implementacja struktury danych Trie
10 Group: Development/Languages/Perl
11 Source0: ftp://ftp.cpan.org/pub/CPAN/modules/by-module/%{pdir}/%{pdir}-%{pnam}-%{version}.tar.gz
12 BuildRequires: perl >= 5.6
13 BuildRequires: rpm-perlprov >= 3.0.3-16
15 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
18 This module implements a trie data structure. The term "trie" comes
19 from the word re*trie*val, but is generally pronounced like "try". A
20 trie is a tree structure (or directed acyclic graph), the nodes of
21 which represent letters in a word. For example, the final lookup for
22 the word 'bob' would look something like
23 $ref->{'b'}{'o'}{'b'}{HASH(0x80c6bbc)} (the HASH being an end
24 marker). Only nodes which would represent words in the trie exist,
25 making the structure slightly smaller than a hash of the same data
29 Ten modu³ jest implementacj± struktury danych Trie. Termin "trie"
30 pochodzi od s³owa "re*trie*val" (odtwarzanie, odzyskiwanie), ale
31 jest wymawiany jak angielskie s³owo "try". Trie to struktura
32 drzewiasta (lub skierowany graf acykliczny), której wêz³y reprezentuj±
33 litery w s³owie. Na przyk³ad, koñcowe wyszukiwanie s³owa "bob" bêdzie
34 wygl±daæ podobnie do $ref->{'b'}{'o'}{'b'}{HASH(0x80c6bbc)} (gdzie
35 HASH jest znacznikiem koñca). W strukturze istniej± tylko wêz³y
36 reprezentuj±ce s³owa, co czyni strukturê mniejsz± ni¿ hasz z tego
40 %setup -q -n %{pdir}-%{pnam}-%{version}
47 rm -rf $RPM_BUILD_ROOT
49 %{__make} install DESTDIR=$RPM_BUILD_ROOT
52 rm -rf $RPM_BUILD_ROOT
55 %defattr(644,root,root,755)
57 %{perl_sitelib}/Tree/Trie.pm