]> git.pld-linux.org Git - packages/Smarty-plugin-gettext.git/blob - Smarty-plugin-gettext.spec
- drop obsolete and outdated manual inclusion of rpm macros
[packages/Smarty-plugin-gettext.git] / Smarty-plugin-gettext.spec
1 %define         php_min_version 5.2.1
2 Summary:        Gettext support for Smarty
3 Summary(pl.UTF-8):      Obsługa gettexta dla systemu Smarty
4 Name:           Smarty-plugin-gettext
5 Version:        1.4.0
6 Release:        1
7 License:        LGPL v2+
8 Group:          Development/Languages/PHP
9 Source0:        https://github.com/smarty-gettext/smarty-gettext/archive/%{version}/smarty-gettext-%{version}.tar.gz
10 # Source0-md5:  2ef33831e5bd530967bbb7400d29787b
11 URL:            https://github.com/smarty-gettext/smarty-gettext
12 BuildRequires:  rpm-php-pearprov
13 BuildRequires:  sed >= 4.0
14 Requires:       Smarty >= 2.6.10-4
15 Requires:       php(core) >= %{php_min_version}
16 Requires:       php(gettext)
17 Requires:       sed >= 4.0
18 Provides:       smarty-gettext = %{version}-%{release}
19 Obsoletes:      smarty-gettext
20 Obsoletes:      smarty-gettext-devel
21 BuildArch:      noarch
22 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
23
24 %define         _smartyplugindir        %{php_data_dir}/Smarty/plugins
25 %define         _smarty3plugindir       %{php_data_dir}/Smarty3/plugins
26
27 # tsmarty2c is deliberately packaged to both packages with same name
28 %define         _duplicate_files_terminate_build   0
29
30 %description
31 smarty-gettext provides gettext support for Smarty, the popular PHP
32 templating engine <http://smarty.php.net/>.
33
34 %description -l pl.UTF-8
35 smarty-gettext dodaje obsługę gettexta do systemu Smarty - popularnego
36 silnika szablonów dla PHP - <http://smarty.php.net/>.
37
38 %package -n php-Smarty-plugin-gettext
39 Summary:        Gettext support for Smarty
40 Summary(pl.UTF-8):      Obsługa gettexta dla systemu Smarty
41 Group:          Development/Languages/PHP
42 Requires:       php(core) >= %{php_min_version}
43 Requires:       php(gettext)
44 Requires:       php-Smarty >= 3.1.8-4
45
46 %description -n php-Smarty-plugin-gettext
47 smarty-gettext provides gettext support for Smarty, the popular PHP
48 templating engine <http://smarty.php.net/>.
49
50 %description -n php-Smarty-plugin-gettext -l pl.UTF-8
51 smarty-gettext dodaje obsługę gettexta do systemu Smarty - popularnego
52 silnika szablonów dla PHP - <http://smarty.php.net/>.
53
54 %prep
55 %setup -q -n smarty-gettext-%{version}
56
57 %{__sed} -i -e '1s,^#!.*php,#!/usr/bin/php,' tsmarty2c.php
58
59 %install
60 rm -rf $RPM_BUILD_ROOT
61 install -d $RPM_BUILD_ROOT{%{_smartyplugindir},%{_smarty3plugindir},%{_bindir}}
62 cp -p block.t.php $RPM_BUILD_ROOT%{_smartyplugindir}
63 cp -p block.t.php $RPM_BUILD_ROOT%{_smarty3plugindir}
64 cp -p tsmarty2c.php $RPM_BUILD_ROOT%{_bindir}/tsmarty2c
65
66 %clean
67 rm -rf $RPM_BUILD_ROOT
68
69 %files
70 %defattr(644,root,root,755)
71 %doc README.md ChangeLog.md
72 %attr(755,root,root) %{_bindir}/tsmarty2c
73 %{_smartyplugindir}/*.php
74
75 %files -n php-Smarty-plugin-gettext
76 %defattr(644,root,root,755)
77 %doc README.md ChangeLog.md
78 %attr(755,root,root) %{_bindir}/tsmarty2c
79 %{_smarty3plugindir}/*.php
This page took 0.085472 seconds and 4 git commands to generate.