]> git.pld-linux.org Git - packages/php-pecl-http.git/blobdiff - php-pecl-http.spec
- use php(core) as dependency to require php version
[packages/php-pecl-http.git] / php-pecl-http.spec
index 3db075ea4949bd2a6d25bc40c06e2063559f90cf..c6a48388e0381c31e46f7c4a002dcd6c23066989 100644 (file)
-%define                _modname        http
-%define                _fmodname       pecl_http
-%define                _status         alpha
-
-Summary:       %{_modname} - extended HTTP support
-Summary(pl):   %{_modname} - rozszerzone wsparcie protoko³u HTTP
-Name:          php-pecl-%{_modname}
-Version:       0.4.0
-Release:       1
-License:       PHP 2.02
+%define                modname http
+%define                fmodname        pecl_http
+%define                status          stable
+Summary:       %{modname} - extended HTTP support
+Summary(pl.UTF-8):     %{modname} - rozszerzona obsługa protokołu HTTP
+Name:          php-pecl-%{modname}
+Version:       1.7.1
+Release:       3
+License:       BSD, revised
 Group:         Development/Languages/PHP
-Source0:       http://pecl.php.net/get/%{_fmodname}-%{version}.tgz
-# Source0-md5: 00946b14eca556ee5c223aaafbd38011
+Source0:       http://pecl.php.net/get/%{fmodname}-%{version}.tgz
+# Source0-md5: 5047574da6b57741896e0463e84dbd8c
 URL:           http://pecl.php.net/package/pecl_http/
-BuildRequires: libtool
+BuildRequires: curl-devel >= 7.12.3
+BuildRequires: openssl-devel
 BuildRequires: php-devel >= 3:5.0.0
-Requires:      php-common >= 3:5.0.0
-Obsoletes:     php-pear-%{_modname}
+BuildRequires: rpmbuild(macros) >= 1.344
+BuildRequires: zlib-devel >= 1.2.0.4
+%{?requires_php_extension}
+Requires:      php(core) >= 5.0.4
+Requires:      php-iconv
+Requires:      php-session
+Obsoletes:     php-pear-%{modname}
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
-%define                _sysconfdir     /etc/php
-%define                extensionsdir   %{_libdir}/php
-
 %description
-Currently implemented features:
-===============================
+This HTTP extension aims to provide a convenient and powerful set of
+functionality for one of PHPs major applications.
+
+It eases handling of HTTP urls, dates, redirects, headers and
+messages, provides means for negotiation of clients preferred language
+and charset, as well as a convenient way to send any arbitrary data
+with caching and resuming capabilities.
 
+It provides powerful request functionality, if built with CURL
+support. Parallel requests are available for PHP 5 and greater.
+
+Currently implemented features include:
 - Building absolute URIs
-- RCF compliant HTTP redirects
-- Caching by "Last-Modified" and/or ETag (with 'on the fly' option)
+- RFC compliant HTTP redirects
+- RFC compliant HTTP date handling
+- Parsing of HTTP headers and messages
+- Caching by "Last-Modified" and/or ETag (with 'on the fly' option for
+  ETag generation from buffered output)
 - Sending data/files/streams with (multiple) ranges support
 - Negotiating user preferred language/charset
-- Convenient request functions to HEAD/GET/POST if libcurl is available
+- Convenient request functions to HEAD/GET/POST if libcurl is
+  available
+- HTTP auth hooks (Basic)
+- PHP5 classes: HttpUtil, HttpResponse, HttpRequest, HttpRequestPool,
+  HttpMessage
+
+In PECL status of this extension is: %{status}.
+
+%description -l pl.UTF-8
+To rozszerzenie HTTP ma na celu dostarczenie wygodnego i potężnego
+zestawu funkcjonalności do jednego z najważniejszych zastosowań PHP.
+
+Ułatwia obsługę adresów HTTP, dat, przekierowań, nagłówków i
+wiadmości, dostarcza sposób do negocjacji preferowanego języka i
+strony kodowej klienta, jak również wygodnego sposobu wysyłania
+dowolnego rodzaju danych z możliwością keszowania oraz wznawiania
+transferów.
+
+Rozszerzenie dostarcza potężne możliwości zapytań, jeśli zbudowane
+jest ze wsparciem dla CURL. Równoległe zapytania są dostępne od wersji
+PHP 5.
 
-In PECL status of this extension is: %{_status}.
+Aktualnie zaimplementowane możliwości to między innymi:
+- tworzenie bezwzględnych URI
+- zgodne z RFC przekierowania HTTP
+- zgodna z RFC obsługa daty HTTP
+- przetwarzanie nagłówków i wiadomości HTTP
+- buforowanie z użyciem "Last-Modified" i/lub ETagów (z opcję
+  generowania "w locie" ETagów z buforowanego wyjścia)
+- wysyłanie danych/plików/strumieni z obsługą (wielu) przedziałów
+- negocjacja preferowanego przez użytkownika języka/zestawu znaków
+- wygodne funkcje do żądań HEAD/GET/POST jeśli dostępna jest libcurl
+- wywołania HTTP auth (Basic)
+- klasy PHP5: HttpUtil, HttpResponse, HttpRequest, HttpRequestPool,
+  HttpMessage
 
-#%description -l pl
-#
-#To rozszerzenie ma w PECL status: %{_status}.
+To rozszerzenie ma w PECL status: %{status}.
 
 %prep
-%setup -q -c
+%setup -qc
+mv %{fmodname}-%{version}/* .
 
 %build
-cd %{_fmodname}-%{version}
 phpize
 %configure
 %{__make}
 
 %install
 rm -rf $RPM_BUILD_ROOT
-install -d $RPM_BUILD_ROOT%{extensionsdir}
+install -d $RPM_BUILD_ROOT{%{php_sysconfdir}/conf.d,%{php_extensiondir}}
 
-install %{_fmodname}-%{version}/modules/%{_modname}.so $RPM_BUILD_ROOT%{extensionsdir}/%{_modname}.so
+install -p modules/%{modname}.so $RPM_BUILD_ROOT%{php_extensiondir}
+cat <<'EOF' > $RPM_BUILD_ROOT%{php_sysconfdir}/conf.d/%{modname}.ini
+; Enable %{modname} extension module
+extension=%{modname}.so
+EOF
 
 %clean
 rm -rf $RPM_BUILD_ROOT
 
 %post
-%{_sbindir}/php-module-install install %{_modname} %{_sysconfdir}/php-cgi.ini
+%php_webserver_restart
 
-%preun
-if [ "$1" = "0" ]; then
-       %{_sbindir}/php-module-install remove %{_modname} %{_sysconfdir}/php-cgi.ini
+%postun
+if [ "$1" = 0 ]; then
+       %php_webserver_restart
 fi
 
 %files
 %defattr(644,root,root,755)
-%doc %{_fmodname}-%{version}/{docs,EXPERIMENTAL}
-%attr(755,root,root) %{extensionsdir}/%{_modname}.so
+%doc KnownIssues.txt docs/*
+%config(noreplace) %verify(not md5 mtime size) %{php_sysconfdir}/conf.d/%{modname}.ini
+%attr(755,root,root) %{php_extensiondir}/%{modname}.so
This page took 0.322173 seconds and 4 git commands to generate.