From 4c2a5e8be6669282194369b0be6342307066fd2b Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Tue, 7 May 2013 15:23:53 +0200 Subject: php-sabredav-Sabre_HTTP: 1.8.1 (upstream PEAR not maintained) --- php-sabredav-Sabre_HTTP.spec | 61 ++++++++++++++++++++++++++++++------------- php-sabredav-Sabre_HTTP.xml | 62 ++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 105 insertions(+), 18 deletions(-) create mode 100644 php-sabredav-Sabre_HTTP.xml diff --git a/php-sabredav-Sabre_HTTP.spec b/php-sabredav-Sabre_HTTP.spec index 0255453..ffefd26 100644 --- a/php-sabredav-Sabre_HTTP.spec +++ b/php-sabredav-Sabre_HTTP.spec @@ -1,16 +1,20 @@ %{!?__pear: %{expand: %%global __pear %{_bindir}/pear}} -%global pear_name %(echo %{name} | sed -e 's/^php-sabredav-//' -e 's/-/_/g') +%global pear_name Sabre_HTTP %global channelname pear.sabredav.org +%global mainver 1.8.5 Name: php-sabredav-Sabre_HTTP -Version: 1.6.4 -Release: 3%{?dist} +Version: 1.8.1 +Release: 1%{?dist} Summary: HTTP component for the SabreDAV WebDAV framework for PHP Group: Development/Libraries License: BSD URL: http://code.google.com/p/sabredav -Source0: http://pear.sabredav.org/get/%{pear_name}-%{version}.tgz +# https://github.com/fruux/sabre-dav/issues/336 +# Please update PEAR channel +Source0: http://sabredav.googlecode.com/files/SabreDAV-%{mainver}.zip +Source1: %{name}.xml BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildArch: noarch @@ -21,7 +25,7 @@ Requires(post): %{__pear} Requires(postun): %{__pear} Requires: php-pear(PEAR) Requires: php-channel(%{channelname}) -Requires: php-pear(%{channelname}/Sabre) +Requires: php-pear(%{channelname}/Sabre) >= 1.0.1 Provides: php-pear(%{pear_name}) = %{version} Provides: php-pear(%{channelname}/%{pear_name}) = %{version} @@ -30,32 +34,49 @@ Provides: php-pear(%{channelname}/%{pear_name}) = %{version} Sabre_HTTP allows for a central interface to deal with Sabre. %prep -%setup -q -c -[ -f package2.xml ] || mv package.xml package2.xml -mv package2.xml %{pear_name}-%{version}/%{pear_name}.xml +%setup -q -n SabreDAV + +cp %{SOURCE1} . +mv lib/Sabre Sabre + +# Check version +extver=$(sed -n "/VERSION/{s/.* '//;s/'.*$//;p}" Sabre/HTTP/Version.php) +if test "x${extver}" != "x%{version}"; then + : Error: Upstream version is ${extver}, expecting %{version}. + exit 1 +fi + +# Check files +touch error.lst +for fic in $(find Sabre/HTTP -type f) +do + grep $fic %{name}.xml || echo $fic >> error.lst +done + +if [ -s error.lst ]; then + : Missing in %{name}.xml + cat error.lst + exit 1 +fi %build # Empty build section, most likely nothing required. %install -cd %{pear_name}-%{version} - -%{__pear} install --nodeps --packagingroot $RPM_BUILD_ROOT %{pear_name}.xml - +%{__pear} install --nodeps --packagingroot %{buildroot} %{name}.xml # Clean up unnecessary files -rm -rf $RPM_BUILD_ROOT%{pear_metadir}/.??* - +rm -rf %{buildroot}%{pear_metadir}/.??* # Install XML package description -mkdir -p $RPM_BUILD_ROOT%{pear_xmldir} -install -pm 644 %{pear_name}.xml $RPM_BUILD_ROOT%{pear_xmldir} +mkdir -p %{buildroot}%{pear_xmldir} +install -pm 644 %{name}.xml %{buildroot}%{pear_xmldir} %post %{__pear} install --nodeps --soft --force --register-only \ - %{pear_xmldir}/%{pear_name}.xml >/dev/null || : + %{pear_xmldir}/%{name}.xml >/dev/null || : %postun if [ $1 -eq 0 ] ; then @@ -67,11 +88,15 @@ fi %files %defattr(-,root,root,-) %doc %{pear_docdir}/%{pear_name} -%{pear_xmldir}/%{pear_name}.xml +%{pear_xmldir}/%{name}.xml %{pear_phpdir}/Sabre/HTTP %changelog +* Tue May 7 2013 Remi Collet 1.8.5-1 +- update to 1.8.1 + use our own package.xml as upstream doesn't use pear anymore + * Mon Nov 12 2012 Remi Collet 1.6.4-3 - backport for remi repo diff --git a/php-sabredav-Sabre_HTTP.xml b/php-sabredav-Sabre_HTTP.xml new file mode 100644 index 0000000..6dcf020 --- /dev/null +++ b/php-sabredav-Sabre_HTTP.xml @@ -0,0 +1,62 @@ + + + Sabre_HTTP + pear.sabredav.org + Sabre_HTTP provides various HTTP helpers, for input and output and authentication + Sabre_HTTP effectively wraps around $_SERVER, php://input, php://output and the headers method, +allowing for a central interface to deal with this as well as easier unittesting. + +In addition Sabre_HTTP provides classes for Basic, Digest and Amazon AWS authentication. + + Evert Pot + Evert Pot + evert@rooftopsolutions.nl + true + + 2012-08-02 + + + 1.8.1 + 1.8.1 + + + stable + stable + + Modified BSD + +New release. Read the ChangeLog and announcement for more details + + + + + + + + + + + + + + + + + + + + + 5.3.1 + + + 1.9 + + + Sabre + pear.sabredav.org + 1.0.0 + + + + + -- cgit