From fc431ff8ec5fad71010b24adabd9eea971b23545 Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Mon, 13 Aug 2012 11:31:38 +0200 Subject: php-pear-XML-RPC: new package (to be dropped from php-pear) --- Makefile | 4 +++ php-pear-XML-RPC.spec | 88 +++++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 92 insertions(+) create mode 100644 Makefile create mode 100644 php-pear-XML-RPC.spec diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..13af741 --- /dev/null +++ b/Makefile @@ -0,0 +1,4 @@ +SRCDIR := $(shell pwd) +NAME := $(shell basename $(SRCDIR)) +include ../../../common/Makefile + diff --git a/php-pear-XML-RPC.spec b/php-pear-XML-RPC.spec new file mode 100644 index 0000000..c42a3b2 --- /dev/null +++ b/php-pear-XML-RPC.spec @@ -0,0 +1,88 @@ +%{!?__pear: %{expand: %%global __pear %{_bindir}/pear}} +%global pear_name XML_RPC + +Name: php-pear-XML-RPC +Version: 1.5.5 +Release: 1%{?dist} +Summary: PHP implementation of the XML-RPC protocol + +Group: Development/Libraries +# PHP License version 3.0.1 +# http://pear.php.net/bugs/19368 request for License file. +License: PHP +URL: http://pear.php.net/package/XML_RPC +Source0: http://pear.php.net/get/%{pear_name}-%{version}.tgz + +BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) +BuildArch: noarch +BuildRequires: php-pear >= 1:1.4.9-1.2 + +Requires(post): %{__pear} +Requires(postun): %{__pear} +Requires: php-pear(PEAR) +# extensions detected by phpci +Requires: php-date, php-mbstring, php-pcre +# also requires php-xml, which is provided by php-common, not php-xml + +Provides: php-pear(%{pear_name}) = %{version} + +%description +A PEAR-ified version of Useful Inc's XML-RPC for PHP. + +It has support for HTTP/HTTPS transport, proxies and authentication. + + +%prep +%setup -q -c +cd %{pear_name}-%{version} +# package.xml is V1, package2.xml is V2 +mv ../package2.xml %{name}.xml + + +%build +cd %{pear_name}-%{version} +# Empty build section, most likely nothing required. + + +%install +cd %{pear_name}-%{version} +rm -rf %{buildroot} +%{__pear} install --nodeps --packagingroot %{buildroot} %{name}.xml + +# Clean up unnecessary files +rm -rf %{buildroot}%{pear_phpdir}/.??* + +# Install XML package description +mkdir -p %{buildroot}%{pear_xmldir} +install -pm 644 %{name}.xml %{buildroot}%{pear_xmldir} + + +%clean +rm -rf %{buildroot} + + +%post +%{__pear} install --nodeps --soft --force --register-only \ + %{pear_xmldir}/%{name}.xml >/dev/null || : + +%postun +if [ $1 -eq 0 ] ; then + %{__pear} uninstall --nodeps --ignore-errors --register-only \ + pear.php.net/%{pear_name} >/dev/null || : +fi + + +%files +%defattr(-,root,root,-) +%{pear_xmldir}/%{name}.xml +%{pear_phpdir}/XML/RPC +%{pear_phpdir}/XML/RPC.php +# this are not real unit test, can't be run in rpmbuild +%{pear_testdir}/%{pear_name} + + +%changelog +* Mon Aug 13 2012 Remi Collet - 1.5.5-1 +- Version 1.5.5 (stable), API 1.5.0 (stable) +- Initial RPM + -- cgit