Search
j0ke.net Open Build Service
>
Projects
>
server:php:applications
>
php5-pear-html_template_it
> php5-pear-html_template_it.spec
Sign Up
|
Log In
Username
Password
Cancel
Overview
Repositories
Revisions
Requests
Users
Advanced
Attributes
Meta
File php5-pear-html_template_it.spec of Package php5-pear-html_template_it (Revision 2)
Currently displaying revision
2
,
show latest
#norootforbuild # # spec file for package HTML_Template_IT (Version 1.2.1) # # Copyright (c) 2007 SuSE Linux AG, Nuernberg, Germany. # This file and all modifications and additions to the pristine # package are under the same license as the package itself. # # Please submit bug fixes or comments via http://bugs.opensuse.org/ # %define peardir %(pear config-get php_dir 2> /dev/null) %define xmldir /var/lib/pear Summary: Integrated Templates Name: php5-pear-html_template_it Version: 1.2.1 Release: 1 License: Modified BSD license Group: Development/Libraries/Other Source0: http://pear.php.net/get/HTML_Template_IT-%{version}.tgz BuildRoot: %{_tmppath}/%{name}-%{version}-build URL: http://pear.php.net/package/HTML_Template_IT BuildRequires: php5-pear PreReq: php5-pear BuildArch: noarch %description HTML_Template_IT: Simple template API. The Isotemplate API is somewhat tricky for a beginner although it is the best one you can build. template::parse() [phplib template = Isotemplate] requests you to name a source and a target where the current block gets parsed into. Source and target can be block names or even handler names. This API gives you a maximum of fexibility but you always have to know what you do which is quite unusual for php skripter like me. I noticed that I do not any control on which block gets parsed into which one. If all blocks are within one file, the script knows how they are nested and in which way you have to parse them. IT knows that inner1 is a child of block2, there's no need to tell him about this. Features : * Nested blocks * Include external file * Custom tags format (default {mytag}) HTML_Template_ITX : With this class you get the full power of the phplib template class. You may have one file with blocks in it but you have as well one main file and multiple files one for each block. This is quite usefull when you have user configurable websites. Using blocks not in the main template allows you to modify some parts of your layout easily. %prep %setup -c -T pear -v -c pearrc \ -d php_dir=%{peardir} \ -d doc_dir=/docs \ -d bin_dir=%{_bindir} \ -d data_dir=%{peardir}/data \ -d test_dir=%{peardir}/tests \ -d ext_dir=%{_libdir} \ -s %build %install pear -c pearrc install --nodeps --packagingroot %{buildroot} %{SOURCE0} # Clean up unnecessary files rm pearrc rm %{buildroot}/%{peardir}/.filemap rm %{buildroot}/%{peardir}/.lock rm -rf %{buildroot}/%{peardir}/.registry rm -rf %{buildroot}%{peardir}/.channels rm %{buildroot}%{peardir}/.depdb rm %{buildroot}%{peardir}/.depdblock mv %{buildroot}/docs . # Install XML package description mkdir -p %{buildroot}%{xmldir} tar -xzf %{SOURCE0} package.xml cp -p package.xml %{buildroot}%{xmldir}/HTML_Template_IT.xml %clean rm -rf %{buildroot} %post pear install --nodeps --soft --force --register-only %{xmldir}/HTML_Template_IT.xml %postun if [ "$1" -eq "0" ]; then pear uninstall --nodeps --ignore-errors --register-only pear.php.net/HTML_Template_IT fi %files %defattr(-,root,root) %doc docs/HTML_Template_IT/* %{peardir}/* %{xmldir}/HTML_Template_IT.xml