]> git.pld-linux.org Git - packages/Smarty.git/blame - Smarty.spec
- don't use separate version for subpackage; braks builder script
[packages/Smarty.git] / Smarty.spec
CommitLineData
9fc5c137 1%define _doc_version 2.6.14
8e2cfc78 2%include /usr/lib/rpm/macros.php
0a03539f 3Summary: Template engine for PHP
554e6959 4Summary(pl.UTF-8): System szablonów dla PHP
0a03539f 5Name: Smarty
d875f5d0 6Version: 2.6.18
b2743ba8 7Release: 2
0a03539f
ŁJM
8License: LGPL
9Group: Development/Languages/PHP
10Source0: http://smarty.php.net/distributions/%{name}-%{version}.tar.gz
d875f5d0 11# Source0-md5: cd9b9c78b43c0d0490b71111b2fe1a99
974fd103 12Source1: http://smarty.php.net/distributions/manual/en/%{name}-%{_doc_version}-docs.tar.gz
9fc5c137 13# Source1-md5: 357510250885aab057853949e35845c7
ceb8190f 14Source2: %{name}-function.html_input_image.php
b5f64aca 15URL: http://smarty.php.net/
57c04d03 16BuildRequires: rpm-php-pearprov >= 4.3
9dd07cd1 17Requires: php-common
0a03539f
ŁJM
18BuildArch: noarch
19BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
0a03539f 20
88a9ca9a
ER
21%define _smartydir %{_datadir}/php/Smarty
22
0a03539f
ŁJM
23%description
24Smarty is a template engine for PHP. Smarty provides your basic
25variable substitution and dynamic block functionality, and also takes
26a step further to be a "smart" template engine, adding features such
27as configuration files, template functions, variable modifiers, and
28making all of this functionality as easy as possible to use for both
29programmers and template designers.
30
b2a044db
JR
31%description -l pl.UTF-8
32Smarty jest systemem szablonów dla PHP. Pozwala na podstawowe
33podstawianie wartości zmiennych oraz dynamiczne operacje na blokach;
34idzie o krok dalej, aby być "mądrym" silnikiem szablonów, dodając
35takie możliwości jak pliki konfiguracyjne, funkcje, zmienne
36modyfikatory oraz czyniąc całą funkcjonalność jak najłatwiejszą w
37użyciu jednocześnie dla programistów i projektantów szablonów.
0a03539f 38
39e0217d 39%package doc
0a03539f 40Summary: Template engine for PHP - documentation
554e6959 41Summary(pl.UTF-8): System szablonów dla PHP - dokumentacja
0a03539f
ŁJM
42Group: Development/Languages/PHP
43
39e0217d 44%description doc
0a03539f
ŁJM
45Documentation for Smarty template engine.
46
b2a044db
JR
47%description doc -l pl.UTF-8
48Dokumentacja do systemu szablonów Smarty.
0a03539f
ŁJM
49
50%prep
0a03539f
ŁJM
51%setup -q -a 1
52
53%install
54rm -rf $RPM_BUILD_ROOT
88a9ca9a
ER
55install -d $RPM_BUILD_ROOT{%{_smartydir}/{internals,plugins},%{php_pear_dir}}
56
57install libs/{Config_File,Smarty{,_Compiler}}.class.php $RPM_BUILD_ROOT%{_smartydir}
58install libs/debug.tpl $RPM_BUILD_ROOT%{_smartydir}
59install libs/internals/*.php $RPM_BUILD_ROOT%{_smartydir}/internals
60install libs/plugins/*.php $RPM_BUILD_ROOT%{_smartydir}/plugins
ceb8190f 61install %{SOURCE2} $RPM_BUILD_ROOT%{_smartydir}/plugins/function.html_input_image.php
0a03539f 62
88a9ca9a
ER
63# backards compatible
64ln -s %{_smartydir} $RPM_BUILD_ROOT%{php_pear_dir}/%{name}
0a03539f
ŁJM
65
66%clean
67rm -rf $RPM_BUILD_ROOT
68
88a9ca9a 69# make compat symlink, the symlink is discarded using %ghost on package uninstall
3e1a4945 70%triggerpostun -- Smarty < 2.6.10-4
88a9ca9a
ER
71if [ -d %{php_pear_dir}/%{name}/plugins ]; then
72 mv %{php_pear_dir}/%{name}/plugins/* %{_smartydir}/plugins
73 rmdir %{php_pear_dir}/%{name}/plugins 2>/dev/null
74fi
75rmdir %{php_pear_dir}/%{name} 2>/dev/null || mv -v %{php_pear_dir}/%{name}{,.rpmsave}
76ln -s %{_smartydir} %{php_pear_dir}/%{name}
77
63fec699 78%post
79[ -e %{php_pear_dir}/%{name} ] || ln -s %{_smartydir} %{php_pear_dir}/%{name}
80
0a03539f
ŁJM
81%files
82%defattr(644,root,root,755)
749d428c 83%doc BUGS ChangeLog FAQ INSTALL NEWS README RELEASE_NOTES TODO
88a9ca9a
ER
84%dir %{_smartydir}
85%dir %{_smartydir}/internals
86%dir %{_smartydir}/plugins
87%{_smartydir}/*.class.php
88%{_smartydir}/debug.tpl
89%{_smartydir}/internals/*.php
90%{_smartydir}/plugins/*.php
91
92# for the sake of bc
93%ghost %{php_pear_dir}/%{name}
0a03539f 94
39e0217d 95%files doc
0a03539f
ŁJM
96%defattr(644,root,root,755)
97%doc manual/*
This page took 0.189495 seconds and 4 git commands to generate.