]> git.pld-linux.org Git - packages/php-pear-XML_HTMLSax3.git/blob - php-pear-XML_HTMLSax3.spec
- drop obsolete and outdated manual inclusion of rpm macros
[packages/php-pear-XML_HTMLSax3.git] / php-pear-XML_HTMLSax3.spec
1 %define         _status         stable
2 %define         _pearname       XML_HTMLSax3
3 Summary:        %{_pearname} - A SAX parser for HTML and other badly formed XML documents
4 Summary(pl.UTF-8):      %{_pearname} - parser SAX dla HTML-a i innych źle uformowanych dokumentów XML
5 Name:           php-pear-%{_pearname}
6 Version:        3.0.0
7 Release:        5
8 License:        PHP
9 Group:          Development/Languages/PHP
10 Source0:        http://pear.php.net/get/%{_pearname}-%{version}.tgz
11 # Source0-md5:  d6b96cbe3ae5f75e54a29ef0d82fd8b6
12 URL:            http://pear.php.net/package/XML_HTMLSax3
13 BuildRequires:  php-pear-PEAR
14 BuildRequires:  rpm-php-pearprov >= 4.4.2-11
15 BuildRequires:  rpmbuild(macros) >= 1.300
16 Requires:       php(core) >= 4.0.5
17 Requires:       php-pear
18 Suggests:       php-pcre
19 Obsoletes:      php-pear-XML_HTMLSax3-tests
20 BuildArch:      noarch
21 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
22
23 %description
24 XML_HTMLSax3 is a SAX based XML parser for badly formed XML documents,
25 such as HTML. The original code base was developed by Alexander Zhukov
26 and published at http://sourceforge.net/projects/phpshelve/. Alexander
27 kindly gave permission to modify the code and license for inclusion in
28 PEAR.
29
30 PEAR::XML_HTMLSax3 provides an API very similar to the native PHP XML
31 extension (http://www.php.net/xml), allowing handlers using one to be
32 easily adapted to the other. The key difference is HTMLSax will not
33 break on badly formed XML, allowing it to be used for parsing HTML
34 documents. Otherwise HTMLSax supports all the handlers available from
35 Expat except namespace and external entity handlers. Provides methods
36 for handling XML escapes as well as JSP/ASP opening and close tags.
37
38 Version 1.x introduced an API similar to the native SAX extension but
39 used a slow character by character approach to parsing.
40
41 Version 2.x has had it's internals completely overhauled to use a
42 Lexer, delivering performance *approaching* that of the native XML
43 extension, as well as a radically improved, modular design that makes
44 adding further functionality easy.
45
46 Version 3.x is about fine tuning the API, behaviour and providing a
47 mechanism to distinguish HTML "quirks" from badly formed HTML (later
48 functionality not yet implemented)
49
50 A big thanks to Jeff Moore (lead developer of WACT:
51 http://wact.sourceforge.net/) who's largely responsible for new
52 design, as well input from other members at Sitepoint's Advanced PHP
53 forums: http://www.sitepointforums.com/showthread.php?threadid=121246.
54
55 Thanks also to Marcus Baker (lead developer of SimpleTest:
56 http://www.lastcraft.com/simple_test.php) for sorting out the unit
57 tests.
58
59 In PEAR status of this package is: %{_status}.
60
61 %description -l pl.UTF-8
62 XML_HTMLSax3 to oparty na SAX parser XML-a dla źle uformowanych
63 dokumentów XML, takich jak HTML. Oryginalny kod bazowy został
64 stworzony przez Alexandra Zhukova i opublikowany pod
65 http://sourceforge.net/projects/phpshelve/. Alexander udzielił
66 pozwolenia na modyfikowanie tego kodu oraz licencji na dołączenie do
67 PEAR-a.
68
69 PEAR::XML_HTMLSax3 udostępnia API bardzo podobne do natywnego
70 rozszerzenia PHP XML (http://www.php.net/xml), co pozwala na łatwe
71 dostosowanie procedur obsługujących używających jednego API do
72 drugiego. Główna różnica polega na tym, że HTMLSax nie załamie się na
73 źle uformowanym XML-u, co pozwala na używanie go do przetwarzania
74 dokumentów HTML. Poza tym HTMLSax obsługuje wszystkie procedury
75 obsługi dostępne w Expacie z wyjątkiem procedur obsługi przestrzeni
76 nazw i zewnętrznych encji. Dostępne są metody do obsługi sekwencji
77 specjalnych XML, a także znaczników otwierających i zamykających
78 JSP/ASP.
79
80 Wersja 1.x wprowadziła API podobne do natywnego rozszerzenia SAX, ale
81 używała wolnego podejścia do przetwarzania (znak po znaku).
82
83 Wersja 2.x miała wnętrzności całkowicie przebudowane do używania
84 Lexera, dostarczając wydajność zbliżoną do natywnego rozszerzenia XML,
85 a także znacząco ulepszoną, modularną architekturę znacznie
86 ułatwiającą dodawanie nowej funkcjonalności.
87
88 Z wersją 3.x związane jest dostrajanie API i zachowania oraz
89 dostępność mechanizmu do rozróżniania sztuczek HTML-owych ze źle
90 uformowanych dokumentów (dalsza funkcjonalność nie została jeszcze
91 zaimplementowana).
92
93 Duże podziękowania należą się Jeffowi Moore (głównemu programiście
94 WACT: http://wact.sourceforge.net/), który jest w znaczący sposób
95 odpowiedzialny za nowy projekt, a także kod od innych członków forów
96 http://www.sitepointforums.com/showthread.php?threadid=121246.
97
98 Podziękowania należą się także Marcusowi Bakerowi (głównemu
99 programiście SimpleTestu: http://www.lastcraft.com/simple_test.php) za
100 uporządkowanie testów jednostkowych.
101
102 Ta klasa ma w PEAR status: %{_status}.
103
104 %prep
105 %pear_package_setup
106
107 %install
108 rm -rf $RPM_BUILD_ROOT
109 install -d $RPM_BUILD_ROOT%{php_pear_dir}
110 %pear_package_install
111
112 %clean
113 rm -rf $RPM_BUILD_ROOT
114
115 %files
116 %defattr(644,root,root,755)
117 %doc install.log
118 %doc docs/%{_pearname}/docs/*
119 %{php_pear_dir}/.registry/*.reg
120 %{php_pear_dir}/XML/*.php
121 %{php_pear_dir}/XML/HTMLSax3
This page took 0.144297 seconds and 4 git commands to generate.