2 # - subpackages for tasks with external dependencies, or rather suggests?
4 %define pearname %{pkgname}
5 %define php_min_version 5.2.2
6 %include /usr/lib/rpm/macros.php
7 Summary: PHP project build system based on Apache Ant
8 Summary(pl.UTF-8): System budowania projektów w PHP oparty na narzędziu Apache Ant
13 Group: Development/Languages/PHP
14 Source0: http://pear.phing.info/get/phing-%{version}.tgz
15 # Source0-md5: d01db5973314178e10899d90cc3d5d15
16 Source1: %{pkgname}.sh
17 Patch0: composer-path.patch
18 URL: http://www.phing.info/
19 BuildRequires: php-channel(pear.phing.info)
20 BuildRequires: php-pear >= 4:1.3.8
21 BuildRequires: php-pear-PEAR >= 1:1.8.0
22 BuildRequires: rpm-php-pearprov >= 4.4.2-11
23 BuildRequires: rpmbuild(macros) >= 1.654
24 BuildRequires: sed >= 4.0
25 Requires: /usr/bin/php
26 Requires: php(core) >= %{php_min_version}
31 Requires: php-channel(pear.phing.info)
35 Suggests: php(gettext)
37 Suggests: php(mbstring)
38 Suggests: php(openssl)
40 Suggests: php(simplexml)
43 Suggests: php-docblox-DocBlox
44 Suggests: php-pdepend-PHP_Depend
45 Suggests: php-pear-Archive_Tar
46 Suggests: php-pear-HTTP_Request2
47 Suggests: php-pear-Net_Growl
48 Suggests: php-pear-PEAR_PackageFileManager
49 Suggests: php-pear-PHP_CodeSniffer
50 Suggests: php-pear-PhpDocumentor
51 Suggests: php-pear-Services_Amazon_S3
52 Suggests: php-pear-VersionControl_Git
53 Suggests: php-pear-VersionControl_SVN
54 Suggests: php-phing-phingdocs
55 Suggests: php-phpmd-PHP_PMD
56 Suggests: php-phpunit-PHP_CodeCoverage
57 Suggests: php-phpunit-phpcpd
58 Suggests: php-phpunit-phploc
59 Suggests: phpunit >= 3.6
60 Provides: phing = %{version}
61 Obsoletes: phing < 2.4.1
62 Conflicts: php-phpunit-PHPUnit < 3.6
64 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
66 %define _appdir %{php_data_dir}/%{pkgname}
68 # exclude optional dependencies
69 %define _noautoreq_pear phing/.* Archive/Tar.* HTTP/Request2.* Log.php Mail.php Mail/mime.php Net/FTP.php Net/Growl.* PEAR.php PEAR/.* PEAR/PackageFileManager.* PHP/CodeCoverage/.* PHP/CodeSniffer.* PHP/Depend/.* PHP/PMD.* PHPMD/.* phpunit/.* vendor/.* PHPLOC/.* PHPUnit/.* Services/Amazon/S3.* Smarty.class.php SmartyBC.class.php System.php VersionControl/.* creole/Creole.php [Pp]hpDocumentor/.* simpletest/.* PHPCPD/Autoload.php SebastianBergmann/PHPCPD/autoload.php Ssh2MethodConnectionParam.php Ssh2MethodParam.php IniFileConfig.php IniFileRemove.php IniFileSet.php Symfony/Component/Stopwatch/autoload.php
71 # exclude optional php dependencies
72 %define _noautophp php-ctype php-ftp php-gettext php-hash php-mbstring php-openssl php-pcre php-simplexml php-xsl
74 # put it together for rpmbuild
75 %define _noautoreq %{?_noautophp}
78 PHing Is Not GNU make; it's a project build system based on Apache
79 Ant. You can do anything with it that you could do with a traditional
80 build system like GNU make, and its use of simple XML build files and
81 extensible PHP "task" classes make it an easy-to-use and highly
82 flexible build framework. Features include file transformations (e.g.
83 token replacement, XSLT transformation, Smarty template
84 transformations), file system operations, interactive build support,
85 SQL execution, CVS operations, tools for creating PEAR packages, and
88 %description -l pl.UTF-8
89 PHing Is Not GNU make (phing to nie GNU make) to system budowania
90 projektów oparty na narzędziu Apache Ant. Pozwala robić wszystko to,
91 co da się zrobić przy użyciu tradycyjnego systemu budowania takiego
92 jak GNU make i wykorzystuje proste pliki reguł XML oraz rozszerzalne
93 klasy PHP "zadań", co czyni z niego łatwe w użyciu i elastyczne
94 środowisko. Możliwości obejmują przekształcenia (np. podstawienia
95 tokenów, przekształcenia XSLT, przekształcenia szablonów Smarty),
96 operacje na systemie plików, obsługę interaktywnego budowania,
97 wywoływanie SQL-a, operacje na CVS-ie, narzędzia do tworzenia pakietów
101 %pear_package_setup -d data_dir=%{_appdir}/data
104 # 2.4.4 release tarball contains .rej and .orig files junk
105 find '(' -name '*~' -o -name '*.orig' -o -name '*.rej' ')' -print0 | xargs -0 -r -l512 rm -f
108 rm -rf $RPM_BUILD_ROOT
109 install -d $RPM_BUILD_ROOT{%{_bindir},%{php_pear_dir},%{_appdir}}
110 %pear_package_install
112 install -p %{SOURCE1} $RPM_BUILD_ROOT%{_bindir}/phing
114 # cleanup the mess pear install made
115 mv $RPM_BUILD_ROOT{%{php_pear_dir}/%{pkgname}/*,%{_appdir}}
116 mv $RPM_BUILD_ROOT{%{php_pear_dir}/phing.php,%{php_data_dir}/phing.php}
117 cp -a ./%{php_data_dir}/* $RPM_BUILD_ROOT%{php_data_dir}
119 #install -d $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
120 #cp -a docs/example/* $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
123 rm -rf $RPM_BUILD_ROOT
126 %pear_package_print_optionalpackages
129 %defattr(644,root,root,755)
130 %doc optional-packages.txt
131 %attr(755,root,root) %{_bindir}/phing
132 %{php_pear_dir}/.registry/.channel.*/phing.reg
133 %{php_data_dir}/phing.php
148 %{_appdir}/lib/Capsule.php
152 #%{_examplesdir}/%{name}-%{version}