]> git.pld-linux.org Git - packages/php-pecl-http.git/blob - php-pecl-http.spec
- updated to 2.4.1
[packages/php-pecl-http.git] / php-pecl-http.spec
1 %define         php_name        php%{?php_suffix}
2 %define         modname http
3 %define         fmodname        pecl_http
4 %define         status          stable
5 Summary:        %{modname} - extended HTTP support
6 Summary(pl.UTF-8):      %{modname} - rozszerzona obsługa protokołu HTTP
7 Name:           %{php_name}-pecl-%{modname}
8 Version:        2.4.1
9 Release:        1
10 License:        BSD, revised
11 Group:          Development/Languages/PHP
12 Source0:        http://pecl.php.net/get/%{fmodname}-%{version}.tgz
13 # Source0-md5:  3d36be8577cf6d46c2372056e22e0669
14 URL:            http://pecl.php.net/package/pecl_http/
15 BuildRequires:  %{php_name}-devel >= 3:5.3.0
16 BuildRequires:  %{php_name}-pecl-propro-devel >= 1.0.0
17 BuildRequires:  %{php_name}-pecl-raphf-devel >= 1.0.0
18 BuildRequires:  curl-devel >= 7.18.2
19 BuildRequires:  openssl-devel
20 BuildRequires:  rpmbuild(macros) >= 1.650
21 BuildRequires:  zlib-devel >= 1.2.0.4
22 %{?requires_php_extension}
23 Requires:       %{php_name}-hash
24 Requires:       %{php_name}-iconv
25 Requires:       %{php_name}-session
26 Provides:       php(%{modname}) = %{version}
27 Obsoletes:      php-pecl-http < 1.7.6-4
28 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
29
30 %description
31 This HTTP extension aims to provide a convenient and powerful set of
32 functionality for one of PHPs major applications.
33
34 It eases handling of HTTP urls, dates, redirects, headers and
35 messages, provides means for negotiation of clients preferred language
36 and charset, as well as a convenient way to send any arbitrary data
37 with caching and resuming capabilities.
38
39 It provides powerful request functionality, if built with CURL
40 support. Parallel requests are available for PHP 5 and greater.
41
42 Currently implemented features include:
43 - Building absolute URIs
44 - RFC compliant HTTP redirects
45 - RFC compliant HTTP date handling
46 - Parsing of HTTP headers and messages
47 - Caching by "Last-Modified" and/or ETag (with 'on the fly' option for
48   ETag generation from buffered output)
49 - Sending data/files/streams with (multiple) ranges support
50 - Negotiating user preferred language/charset
51 - Convenient request functions to HEAD/GET/POST if libcurl is
52   available
53 - HTTP auth hooks (Basic)
54 - PHP5 classes: HttpUtil, HttpResponse, HttpRequest, HttpRequestPool,
55   HttpMessage
56
57 In PECL status of this extension is: %{status}.
58
59 %description -l pl.UTF-8
60 To rozszerzenie HTTP ma na celu dostarczenie wygodnego i potężnego
61 zestawu funkcjonalności do jednego z najważniejszych zastosowań PHP.
62
63 Ułatwia obsługę adresów HTTP, dat, przekierowań, nagłówków i
64 wiadmości, dostarcza sposób do negocjacji preferowanego języka i
65 strony kodowej klienta, jak również wygodnego sposobu wysyłania
66 dowolnego rodzaju danych z możliwością keszowania oraz wznawiania
67 transferów.
68
69 Rozszerzenie dostarcza potężne możliwości zapytań, jeśli zbudowane
70 jest ze wsparciem dla CURL. Równoległe zapytania są dostępne od wersji
71 PHP 5.
72
73 Aktualnie zaimplementowane możliwości to między innymi:
74 - tworzenie bezwzględnych URI
75 - zgodne z RFC przekierowania HTTP
76 - zgodna z RFC obsługa daty HTTP
77 - przetwarzanie nagłówków i wiadomości HTTP
78 - buforowanie z użyciem "Last-Modified" i/lub ETagów (z opcję
79   generowania "w locie" ETagów z buforowanego wyjścia)
80 - wysyłanie danych/plików/strumieni z obsługą (wielu) przedziałów
81 - negocjacja preferowanego przez użytkownika języka/zestawu znaków
82 - wygodne funkcje do żądań HEAD/GET/POST jeśli dostępna jest libcurl
83 - wywołania HTTP auth (Basic)
84 - klasy PHP5: HttpUtil, HttpResponse, HttpRequest, HttpRequestPool,
85   HttpMessage
86
87 To rozszerzenie ma w PECL status: %{status}.
88
89 %prep
90 %setup -qc
91 mv %{fmodname}-%{version}/* .
92
93 %build
94 phpize
95 %{__libtoolize}
96 %configure \
97         PHP_RAPHF=raphf \
98         PHP_PROPRO=propro
99 %{__make}
100
101 %install
102 rm -rf $RPM_BUILD_ROOT
103 install -d $RPM_BUILD_ROOT{%{php_sysconfdir}/conf.d,%{php_extensiondir}}
104
105 install -p modules/%{modname}.so $RPM_BUILD_ROOT%{php_extensiondir}
106 cat <<'EOF' > $RPM_BUILD_ROOT%{php_sysconfdir}/conf.d/%{modname}.ini
107 ; Enable %{modname} extension module
108 extension=%{modname}.so
109 EOF
110
111 %clean
112 rm -rf $RPM_BUILD_ROOT
113
114 %post
115 %php_webserver_restart
116
117 %postun
118 if [ "$1" = 0 ]; then
119         %php_webserver_restart
120 fi
121
122 %files
123 %defattr(644,root,root,755)
124 %doc KnownIssues.txt Exceptions.txt ThanksTo.txt CREDITS
125 %config(noreplace) %verify(not md5 mtime size) %{php_sysconfdir}/conf.d/%{modname}.ini
126 %attr(755,root,root) %{php_extensiondir}/%{modname}.so
This page took 0.078333 seconds and 3 git commands to generate.