]>
Commit | Line | Data |
---|---|---|
48ef24da | 1 | %define php_min_version 5.2.1 |
63723715 | 2 | Summary: Gettext support for Smarty |
924f14f7 | 3 | Summary(pl.UTF-8): Obsługa gettexta dla systemu Smarty |
48ef24da | 4 | Name: Smarty-plugin-gettext |
d3854cc7 | 5 | Version: 1.4.0 |
bb17d5c2 | 6 | Release: 1 |
63723715 ER |
7 | License: LGPL v2+ |
8 | Group: Development/Languages/PHP | |
05d2ddd8 | 9 | Source0: https://github.com/smarty-gettext/smarty-gettext/archive/%{version}/smarty-gettext-%{version}.tar.gz |
d3854cc7 | 10 | # Source0-md5: 2ef33831e5bd530967bbb7400d29787b |
05d2ddd8 | 11 | URL: https://github.com/smarty-gettext/smarty-gettext |
ddf8fc27 | 12 | BuildRequires: rpm-php-pearprov |
63723715 ER |
13 | BuildRequires: sed >= 4.0 |
14 | Requires: Smarty >= 2.6.10-4 | |
1ea57013 | 15 | Requires: php(core) >= %{php_min_version} |
af38e0ab | 16 | Requires: php(gettext) |
bb17d5c2 | 17 | Requires: sed >= 4.0 |
48ef24da ER |
18 | Provides: smarty-gettext = %{version}-%{release} |
19 | Obsoletes: smarty-gettext | |
20 | Obsoletes: smarty-gettext-devel | |
63723715 ER |
21 | BuildArch: noarch |
22 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
23 | ||
2e412f50 ER |
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 | |
63723715 ER |
29 | |
30 | %description | |
31 | smarty-gettext provides gettext support for Smarty, the popular PHP | |
32 | templating engine <http://smarty.php.net/>. | |
33 | ||
103be048 JR |
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/>. | |
6886e5dc | 37 | |
2fb1a223 ER |
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 | |
2fb1a223 ER |
42 | Requires: php(core) >= %{php_min_version} |
43 | Requires: php(gettext) | |
2e412f50 | 44 | Requires: php-Smarty >= 3.1.8-4 |
2fb1a223 ER |
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 | ||
63723715 | 54 | %prep |
bb17d5c2 ER |
55 | %setup -q -n smarty-gettext-%{version} |
56 | ||
57 | %{__sed} -i -e '1s,^#!.*php,#!/usr/bin/php,' tsmarty2c.php | |
63723715 ER |
58 | |
59 | %install | |
60 | rm -rf $RPM_BUILD_ROOT | |
2fb1a223 | 61 | install -d $RPM_BUILD_ROOT{%{_smartyplugindir},%{_smarty3plugindir},%{_bindir}} |
2e412f50 ER |
62 | cp -p block.t.php $RPM_BUILD_ROOT%{_smartyplugindir} |
63 | cp -p block.t.php $RPM_BUILD_ROOT%{_smarty3plugindir} | |
bb17d5c2 | 64 | cp -p tsmarty2c.php $RPM_BUILD_ROOT%{_bindir}/tsmarty2c |
63723715 ER |
65 | |
66 | %clean | |
67 | rm -rf $RPM_BUILD_ROOT | |
68 | ||
69 | %files | |
70 | %defattr(644,root,root,755) | |
bb17d5c2 | 71 | %doc README.md ChangeLog.md |
827d9419 | 72 | %attr(755,root,root) %{_bindir}/tsmarty2c |
48ef24da | 73 | %{_smartyplugindir}/*.php |
2fb1a223 ER |
74 | |
75 | %files -n php-Smarty-plugin-gettext | |
76 | %defattr(644,root,root,755) | |
bb17d5c2 | 77 | %doc README.md ChangeLog.md |
2fb1a223 ER |
78 | %attr(755,root,root) %{_bindir}/tsmarty2c |
79 | %{_smarty3plugindir}/*.php |