]> git.pld-linux.org Git - packages/python-urllib3.git/blame - python-urllib3.spec
- updated to 1.23
[packages/python-urllib3.git] / python-urllib3.spec
CommitLineData
fb337b23 1# TODO: use system six, [backports.]ssl_match_hostname
d1b278cf 2#
f980972e 3# Conditional build:
d1b278cf
JB
4%bcond_without python2 # CPython 2.x module
5%bcond_without python3 # CPython 3.x module
1cbae8fc 6%bcond_without doc # Sphinx documentation
fb337b23 7%bcond_with tests # test target (uses network etc.)
5381b073
ER
8
9%define module urllib3
f980972e 10Summary: HTTP library with thread-safe connection pooling, file post, and more
d1b278cf 11Summary(pl.UTF-8): Biblioteka HTTP z bezpieczną wątkowo pulą połączeń, wysyłaniem plików itd.
f980972e 12Name: python-%{module}
1cbae8fc
JB
13Version: 1.23
14Release: 1
f980972e
ŁK
15License: MIT
16Group: Development/Languages/Python
1cbae8fc
JB
17Source0: https://files.pythonhosted.org/packages/source/u/urllib3/%{module}-%{version}.tar.gz
18# Source0-md5: 1ad43e4b5ab7a0794c89dc057e1d7179
f980972e
ŁK
19URL: http://urllib3.readthedocs.org/
20%if %{with python2}
21BuildRequires: python-modules >= 1:2.7
fb337b23
JB
22%if %{with tests}
23BuildRequires: python-PySocks >= 1.5.6
24BuildRequires: python-PySocks < 2.0
25BuildRequires: python-mock
26BuildRequires: python-nose
27BuildRequires: python-tornado
28# SO_REUSEPORT option
29BuildRequires: uname(release) >= 3.9
30%endif
f980972e
ŁK
31%endif
32%if %{with python3}
1cbae8fc 33BuildRequires: python3-modules >= 1:3.4
fb337b23
JB
34%if %{with tests}
35BuildRequires: python3-PySocks >= 1.5.6
36BuildRequires: python3-PySocks < 2.0
37BuildRequires: python3-nose
38BuildRequires: python3-tornado
39# SO_REUSEPORT option
40BuildRequires: uname(release) >= 3.9
41%endif
f980972e
ŁK
42%endif
43BuildRequires: rpm-pythonprov
fb337b23 44BuildRequires: rpmbuild(macros) >= 1.714
1cbae8fc
JB
45%if %{with doc}
46BuildRequires: sphinx-pdg
47%endif
f980972e
ŁK
48Requires: python-modules >= 1:2.7
49BuildArch: noarch
50BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
51
52%description
d1b278cf 53Python 2 HTTP module with connection pooling and file POST abilities.
f980972e
ŁK
54Features are:
55- Re-use the same socket connection for multiple requests (with
56 optional client-side certificate verification).
57- File posting (encode_multipart_formdata).
58- Built-in redirection and retries (optional).
59- Supports gzip and deflate decoding.
60- Thread-safe and sanity-safe.
61
d1b278cf
JB
62%description -l pl.UTF-8
63Moduł HTTP dla Pythona 2 z pulą połączeń i możliwością wysyłania
64plików metodą POST. Możliwości:
65- używanie tego samego połączenia dla wielu żądań (z opcjonalną
66 weryfikacją certyfikatu po stronie klienta)
67- wysyłanie plików (encode_multipart_formdata)
68- wbudowane przekierowania i ponawianie prób (opcjonalne)
69- obsługa kodowań gzip i deflate
70- bezpieczeństwo względem wątków.
71
f980972e
ŁK
72%package -n python3-urllib3
73Summary: HTTP library with thread-safe connection pooling, file post, and more
d1b278cf 74Summary(pl.UTF-8): Biblioteka HTTP z bezpieczną wątkowo pulą połączeń, wysyłaniem plików itd.
f980972e 75Group: Development/Languages/Python
1cbae8fc 76Requires: python3-modules >= 1:3.4
f980972e
ŁK
77
78%description -n python3-urllib3
d1b278cf 79Python 3 HTTP module with connection pooling and file POST abilities.
f980972e
ŁK
80Features are:
81- Re-use the same socket connection for multiple requests (with
82 optional client-side certificate verification).
83- File posting (encode_multipart_formdata).
84- Built-in redirection and retries (optional).
85- Supports gzip and deflate decoding.
86- Thread-safe and sanity-safe.
87
d1b278cf
JB
88%description -n python3-urllib3 -l pl.UTF-8
89Moduł HTTP dla Pythona 3 z pulą połączeń i możliwością wysyłania
90plików metodą POST. Możliwości:
91- używanie tego samego połączenia dla wielu żądań (z opcjonalną
92 weryfikacją certyfikatu po stronie klienta)
93- wysyłanie plików (encode_multipart_formdata)
94- wbudowane przekierowania i ponawianie prób (opcjonalne)
95- obsługa kodowań gzip i deflate
96- bezpieczeństwo względem wątków.
97
1cbae8fc
JB
98%package apidocs
99Summary: API documentation for Python urllib3 module
100Summary(pl.UTF-8): Dokumentacja API modułu Pythona urllib3
101Group: Documentation
102
103%description apidocs
104API documentation for Python urllib3 module.
105
106%description apidocs -l pl.UTF-8
107Dokumentacja API modułu Pythona urllib3.
108
f980972e
ŁK
109%prep
110%setup -q -n %{module}-%{version}
111
112%build
113%if %{with python2}
fb337b23 114%py_build %{?with_tests:test}
f980972e
ŁK
115%endif
116
117%if %{with python3}
fb337b23 118%py3_build %{?with_tests:test}
f980972e
ŁK
119%endif
120
1cbae8fc
JB
121%if %{with doc}
122%{__make} -C docs html
123%endif
124
f980972e
ŁK
125%install
126rm -rf $RPM_BUILD_ROOT
127
128%if %{with python2}
fb337b23 129%py_install
f980972e
ŁK
130%py_postclean
131%endif
132
133%if %{with python3}
fb337b23 134%py3_install
fb337b23 135%endif
f980972e
ŁK
136
137%clean
138rm -rf $RPM_BUILD_ROOT
139
140%if %{with python2}
141%files
142%defattr(644,root,root,755)
fb337b23 143%doc CHANGES.rst CONTRIBUTORS.txt LICENSE.txt README.rst
f980972e 144%{py_sitescriptdir}/%{module}
f980972e
ŁK
145%{py_sitescriptdir}/%{module}-%{version}-py*.egg-info
146%endif
f980972e
ŁK
147
148%if %{with python3}
149%files -n python3-urllib3
150%defattr(644,root,root,755)
fb337b23 151%doc CHANGES.rst CONTRIBUTORS.txt LICENSE.txt README.rst
f980972e
ŁK
152%{py3_sitescriptdir}/%{module}
153%{py3_sitescriptdir}/%{module}-%{version}-py*.egg-info
154%endif
1cbae8fc
JB
155
156%if %{with doc}
157%files apidocs
158%defattr(644,root,root,755)
159%doc docs/_build/html/{_static,reference,*.html,*.js}
160%endif
This page took 0.776001 seconds and 4 git commands to generate.