Name: php-Smarty-gettext Version: 1.0 Release: 0.3.b1%{?dist} Summary: Gettext support for Smarty Group: Development/Libraries License: LGPLv2 URL: http://smarty.incutio.com/?page=SmartyGettext Source0: http://sourceforge.net/projects/smarty-gettext/files/smarty-gettext/1.0b1/smarty-gettext-1.0b1.tgz Source1: tsmarty2c.1 BuildRoot: %(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX) # Shebang must be fixed with the bindir path Patch0: 01_shebang_fix.patch # https://sourceforge.net/tracker/?func=detail&aid=3302586&group_id=107853&atid=648884 Patch1: 02_fsf_address_fix.patch Requires: php-Smarty BuildArch: noarch Obsoletes: smarty-gettext <= 1.0-0.1b1 Provides: smarty-gettext = %{version}-%{release} %description Smarty gettext plug-in provides an internationalization support for the PHP template engine Smarty. %prep %setup -q -n smarty-gettext-%{version}b1 # Applying patches %patch0 -p1 %patch1 -p1 # UNIX format conversion for fic in ChangeLog README COPYING; do touch -r $fic .timestamp sed -i -e 's/\f//;s/\r//g' $fic touch -r .timestamp $fic done %build %install # Clean buildroot before install rm -rf %{buildroot} # Install the Smarty Plugin install -d -m 0755 %{buildroot}%{_datadir}/php/Smarty/plugins install -p -m 0644 block.t.php %{buildroot}%{_datadir}/php/Smarty/plugins # Install the command line utility install -d %{buildroot}%{_bindir} install -p -m 0755 tsmarty2c.php %{buildroot}%{_bindir}/tsmarty2c # Manpage installation mkdir -p %{buildroot}%{_mandir}/man1/ install -m 0644 %{SOURCE1} %{buildroot}%{_mandir}/man1/ %clean rm -rf %{buildroot} %files %defattr(-,root,root,-) %doc README COPYING ChangeLog %{_datadir}/php/Smarty/plugins/block.t.php %{_bindir}/tsmarty2c %attr(0644,root,root) %{_mandir}/man1/tsmarty2c.1.gz %changelog * Thu Aug 23 2011 Olivier BONHOMME - 1.0-0.3.b1 - Add manpage for tsmarty2c script * Sat Jul 02 2011 Olivier BONHOMME - 1.0-0.2.b1 - Compliancy with Fedora Policy * Fri Jul 01 2011 Olivier BONHOMME - 1.0-0.1.b1 - Renaming version - Correct Source URL * Fri Apr 29 2011 Olivier BONHOMME - 1.0b1-1 - Initial Release