1 %include /usr/lib/rpm/macros.php
5 %define _pearname %{_class}_%{_subclass}
9 Summary: %{_pearname} - comfortable processing of texts in images
10 Summary(pl.UTF-8): %{_pearname} - komfortowe przetwarzanie tekstu w obrazkach
11 Name: php-pear-%{_pearname}
13 Release: 0.%{subver}.%{rel}
15 Group: Development/Languages/PHP
16 Source0: http://pear.php.net/get/%{_pearname}-%{version}%{subver}.tgz
17 # Source0-md5: 11ef956fc2a93fd359a80bde7fc0e8e8
18 URL: http://pear.php.net/package/Image_Text/
19 BuildRequires: php-pear-PEAR
20 BuildRequires: rpm-php-pearprov >= 4.4.2-11
21 BuildRequires: rpmbuild(macros) >= 1.300
25 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
28 This class allows you to add text to dynamic generated images more
29 comfortable. It allows you to process multiline text and manipulate:
33 Another nice feature is to let the class measurize your text in respect
34 to font size and line splitting to fit a given text box.
36 In PEAR status of this package is: %{_status}.
38 %description -l pl.UTF-8
39 Ta klasa pozwala na dodanie tekstu do dynamicznie generowanych
40 obrazków w sposób bardziej komfortowy niż dotychczas. Możliwe jest
41 przetwarzanie tekstów wielolinijkowych i manipulowanie:
45 Inną ciekawą cechą jest pozwolenie klasie na zmierzenie tekstu w
46 zależności od rozmiaru czcionki i dzielenie go na linie, aby zmieścił
47 się w podanym polu tekstowym.
49 Ta klasa ma w PEAR status: %{_status}.
52 Summary: Tests for PEAR::%{_pearname}
53 Summary(pl.UTF-8): Testy dla PEAR::%{_pearname}
54 Group: Development/Languages/PHP
55 Requires: %{name} = %{version}-%{release}
56 Requires: fonts-TTF-bitstream-vera
61 Tests for PEAR::%{_pearname}.
63 %description tests -l pl.UTF-8
64 Testy dla PEAR::%{_pearname}.
69 # tests -> tests/%{_pearname}
70 install -d ./%{php_pear_dir}/tests/.tmp
71 mv ./%{php_pear_dir}/tests/{*,.tmp}
72 mv ./%{php_pear_dir}/tests/{.tmp,%{_pearname}}
75 sed -i -e "s,'Vera.ttf','/usr/share/fonts/TTF/Vera.ttf'," usr/share/pear/tests/Image_Text/TextTest.php
76 sed -i -e "s,'Vera.ttf','/usr/share/fonts/TTF/Vera.ttf'," docs/Image_Text/example/example.php
77 sed -i -e 's,"./Vera.ttf","/usr/share/fonts/TTF/Vera.ttf",' docs/Image_Text/example/example.php
80 rm -rf $RPM_BUILD_ROOT
81 install -d $RPM_BUILD_ROOT{%{php_pear_dir},%{_bindir}}
84 rm -f $RPM_BUILD_ROOT%{php_pear_dir}/data/Image_Text/tests/Vera.ttf
87 rm -rf $RPM_BUILD_ROOT
90 %defattr(644,root,root,755)
92 %doc docs/%{_pearname}/example
93 %{php_pear_dir}/.registry/*.reg
94 %{php_pear_dir}/%{_class}/*.php
97 %defattr(644,root,root,755)
98 %{php_pear_dir}/tests/%{_pearname}